rename view
This commit is contained in:
16
frontend/static/js/views/AbstractNonAuthentified.js
Normal file
16
frontend/static/js/views/AbstractNonAuthentified.js
Normal file
@ -0,0 +1,16 @@
|
||||
import { client, navigateTo } from "../index.js";
|
||||
import AbstractRedirectView from "./AbstractRedirectView.js";
|
||||
|
||||
export default class extends AbstractRedirectView{
|
||||
constructor(params, url) {
|
||||
super(params, url);
|
||||
}
|
||||
|
||||
async redirect()
|
||||
{
|
||||
if (await client.isAuthentificate() === false)
|
||||
return 0;
|
||||
navigateTo(this.redirect_url);
|
||||
return 1;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user