LaCollision Posted March 11, 2019 Posted March 11, 2019 Hi, In my app, I've created Content Items that don't have a container (it's something possible, like the Status updates that don't belong to a container). My Content Items are followable, so they implement IPS\Content\Followable. However, I'm facing a bug with the "followed" section, available at the address "/followed". In the file core/modules/front/system/followed.php, at line 96, there is a call to a new \IPS\core\Followed\Table(). And in this object, the construct() method calls the $className::$containerNodeClass property… which fires an exception 😭 => Could it be possible, in this constructor, to check the presence of the $containerNodeClass property in the Content item? If this property is not declared, then the join on the core_permission_index table would not be done. Usually, throughout the Suite, the presence of the $containerNodeClass property is checked before calling it, to avoid such an error. That would be really great to add that verification to the followed section. Thank you!
Adriano Faria Posted March 11, 2019 Posted March 11, 2019 Follow, tags and search requires a container. You better add a dummy container as I did here and have everything working.
Sonya* Posted March 11, 2019 Posted March 11, 2019 I had the same issue with my own app. I don't really need a container, but I had some issues similar to yours. I had to implement a dummy container as Adriano says to avoid errors. But I would also appreciate if there were a clear way to have content items without container if they are not really needed.
LaCollision Posted March 11, 2019 Author Posted March 11, 2019 Thank you very much @Adriano Faria and @Sonya*. Too bad we're forced to create dummy containers for Content Items… that doesn't make sense. Especially knowing that in many areas of the code, the presence of the container is checked before calling it, allowing for Content Items to not have a container. That would be great to extend this verification everywhere in the Suite.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.