16 lines
417 B
TypeScript
16 lines
417 B
TypeScript
export default {
|
|
methods: {
|
|
async validateSession(callback: CallableFunction) {
|
|
window.axios
|
|
.get("/ping")
|
|
.then((response) => {
|
|
if (response.status !== 200) {
|
|
callback();
|
|
}
|
|
})
|
|
.catch(() => {
|
|
callback();
|
|
});
|
|
},
|
|
},
|
|
};
|