You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The route:list command currently uses \Magento\Framework\Module\Dir\Reader->getActionFiles() to find classes in every module's Controller directory. However, all of these classes don't actually represent an actual route, as there can be things like abstract classes, interfaces, or just plain non-action classes.
Current Implementation
The
route:list
command currently uses\Magento\Framework\Module\Dir\Reader->getActionFiles()
to find classes in every module'sController
directory. However, all of these classes don't actually represent an actual route, as there can be things like abstract classes, interfaces, or just plain non-action classes.Suggested Enhancement
Check each class before including it. This can be done at the start of the foreach in ListCommand.php. Using is_a($fullActionPath, '\Magento\Framework\App\ActionInterface', true) to check if the class implements ActionInterface would catch all non-action classes, then reflection could be used to also catch any abstract classes.
Expected Benefits
route:list
would no longer list results that are not accessible paths.The text was updated successfully, but these errors were encountered: