- Issue created by @drupatz
Automatically closed - issue fixed for 2 weeks with no activity.
GroupContentMenuHooks::entityPredelete
, introduced in 3.0.6, carries a highly dangerous code which could delete all (!) menu links. This method runs for every entity being deleted and doesn't check if the deleted entity is an entity of GroupContentMenu, before calling deleteLinksInMenu
. It builds the menu_name to delete from out the MENU_PREFIX
string which is group_menu_link_content-
and the entity id --- this means: when i delete node 12 or media 12 or whatever and unfortunately have a menu with the menu_name "group_menu_link_content-12" --- these links would be deleted, although i never meant to do this. In my case, as i have an update script which deletes hundreds of entities of node type X, my menus are completely empty.
Flagging this as "critical", as i cannot think of any lower priority for this.
Update to 3.0.6 and delete any entity which has the same id as an existing GroupContentMenu
entity --- the links of this menu will get deleted.
Check for GroupContentMenuInterface
prior to call deleteLinksInMenu
.
Active
3.0
Code
Automatically closed - issue fixed for 2 weeks with no activity.