mirror of
https://github.com/Tautulli/Tautulli.git
synced 2025-07-07 21:51:14 -07:00
Redirect internally after login instead of client side
* Fixes Tautulli/Tautulli-Issues#300
This commit is contained in:
parent
674966510d
commit
6a534ade9f
2 changed files with 5 additions and 1 deletions
|
@ -160,7 +160,7 @@
|
||||||
dataType: 'json',
|
dataType: 'json',
|
||||||
statusCode: {
|
statusCode: {
|
||||||
200: function(xhr, status) {
|
200: function(xhr, status) {
|
||||||
window.location = "${redirect_uri or http_root}";
|
window.location = "redirect?redirect_uri=${redirect_uri}";
|
||||||
},
|
},
|
||||||
401: function(xhr, status) {
|
401: function(xhr, status) {
|
||||||
if (plex) {
|
if (plex) {
|
||||||
|
|
|
@ -419,3 +419,7 @@ class AuthController(object):
|
||||||
logger.debug("Tautulli WebAuth :: Invalid Plex OAuth login attempt.")
|
logger.debug("Tautulli WebAuth :: Invalid Plex OAuth login attempt.")
|
||||||
cherrypy.response.status = 401
|
cherrypy.response.status = 401
|
||||||
return error_message
|
return error_message
|
||||||
|
|
||||||
|
@cherrypy.expose
|
||||||
|
def redirect(self, redirect_uri='', *args, **kwargs):
|
||||||
|
raise cherrypy.HTTPRedirect(plexpy.HTTP_ROOT + redirect_uri.strip('/'))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue