function registration_link_uninstall in Registration Link 8
File
- ./
registration_link.module, line 5
Code
function registration_link_uninstall() {
// delete the links, that this module has created
$menuLinkManager = \Drupal::service('plugin.manager.menu.link');
$result = $menuLinkManager
->loadLinksByRoute('registration_link.register', array());
foreach ($result as $link) {
// TODO: check for link id
$link
->deleteLink();
}
}