Correct order of permission checking for the root command.