moved locale middleware into its own file
documentation for locale middleware
slightly refactorings for the passport middleware, reenabled some other middlewares