Fix ordering of routes when a subapplication is embedded