forked from v4l3n71n/covas-bo
14 lines
290 B
JavaScript
14 lines
290 B
JavaScript
function checkToken(){
|
|
|
|
instance.get("token", { withCredentials: true})
|
|
.then(function(response) {
|
|
if(location.href.pathname == "/")
|
|
{
|
|
location.href="/html/home.html";
|
|
}
|
|
})
|
|
.catch(function(error){
|
|
location.href="/";
|
|
});
|
|
|
|
} |