Moved setting appName to beforeRoute function