My app consists of two sides, the public side(default/index) accessible to anyone from anywhere and the private side(admin/index) accessible to only administrators. I moved the function responsible for authentication from the 'default.py' controller to the 'admin.py' as the public side requires no authorization to access but when I use the
decorator on the admin side the user gets redirected to 'default/user/login' which no longer exist. please how can I make the authentication redirect to 'admin/user' instead?