Skip to content

Commit

Permalink
perf: Login timeout open in a new window
Browse files Browse the repository at this point in the history
  • Loading branch information
feng626 committed Aug 8, 2024
1 parent c40770d commit eea1d7a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/app/services/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ export class AppService {
clearInterval(this.checkIntervalId);
const ok = confirm(this._i18n.instant(this.getErrorMsg(status)));
if (ok && !this.newLoginHasOpen) {
window.open('/core/auth/login/?next=/luna/', '_self');
window.open('/core/auth/login/?next=/luna/', '_blank');
this.newLoginHasOpen = true;
}
setTimeout(() => this.doCheckProfile(true), 5000);
Expand Down
2 changes: 1 addition & 1 deletion src/app/services/http.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ export class HttpService {
if (error.status === 401 && User.logined) {
const msg = await this._i18n.t('LoginExpireMsg');
if (confirm(msg)) {
window.open('/core/auth/login/?next=/luna/', '_self');
window.open('/core/auth/login/?next=/luna/', '_blank');
}
} else if (error.status === 403) {
const msg = await this._i18n.t('No permission');
Expand Down

0 comments on commit eea1d7a

Please sign in to comment.