fix(menu): check if admin page menu items exist before sorting them

Allow admin page menu to be altered without causing WSOD. Adds regression test
Fixes #6379