|
|
@ -612,8 +612,13 @@ angular.module('myApp.controllers', ['myApp.i18n']) |
|
|
|
}, function (error) { |
|
|
|
}, function (error) { |
|
|
|
if (error.code == 401) { |
|
|
|
if (error.code == 401) { |
|
|
|
MtpApiManager.logOut()['finally'](function () { |
|
|
|
MtpApiManager.logOut()['finally'](function () { |
|
|
|
|
|
|
|
if (location.protocol == 'http:' && |
|
|
|
|
|
|
|
Config.App.domains.indexOf(location.hostname) != -1) { |
|
|
|
|
|
|
|
location = 'https://web.telegram.org/#/login'; |
|
|
|
|
|
|
|
} else { |
|
|
|
location.hash = '/login'; |
|
|
|
location.hash = '/login'; |
|
|
|
AppRuntimeManager.reload(); |
|
|
|
AppRuntimeManager.reload(); |
|
|
|
|
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
error.handled = true; |
|
|
|
error.handled = true; |
|
|
|
} |
|
|
|
} |
|
|
|