fix(striker-ui): correct /login to post with-credentials enabled

main
Tsu-ba-me 2 years ago
parent 4bbdcc1687
commit 0f223950e4
  1. 7
      striker-ui/components/GatePanel.tsx

@ -26,7 +26,11 @@ const GatePanel: FC = () => {
setIsSubmitting(true);
api
.post('/auth/login', { username, password })
.post(
'/auth/login',
{ username, password },
{ withCredentials: true },
)
.then(() => {
router.push('/');
})
@ -34,6 +38,7 @@ const GatePanel: FC = () => {
const emsg = handleAPIError(error, {
onResponseErrorAppend: () => ({
children: `Credentials mismatched.`,
type: 'warning',
}),
});

Loading…
Cancel
Save