forked from Alex/Pterodactyl-Panel
fix: use POST for admin logout route (#3710)
Quick fix for logging out from the admin panel as the auth route was changed from GET to POST.
This commit is contained in:
parent
4dca4f0aa9
commit
d0663dcbd4
@ -195,9 +195,17 @@
|
|||||||
cancelButtonColor: '#d33',
|
cancelButtonColor: '#d33',
|
||||||
confirmButtonText: 'Log out'
|
confirmButtonText: 'Log out'
|
||||||
}, function () {
|
}, function () {
|
||||||
window.location = $(that).attr('href');
|
$.ajax({
|
||||||
|
type: 'POST',
|
||||||
|
url: '{{ route('auth.logout') }}',
|
||||||
|
data: {
|
||||||
|
_token: '{{ csrf_token() }}'
|
||||||
|
},complete: function () {
|
||||||
|
window.location.href = '{{route('auth.login')}}';
|
||||||
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
});
|
||||||
</script>
|
</script>
|
||||||
@endif
|
@endif
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user