Open stephendewyer opened 6 months ago
I am experiencing virtually the exact same issue with the exact same setup, but in the Next.JS codebase.
Have the same problem
Edit by maintainer bot: Comment was automatically minimized because it was considered unhelpful. (If you think this was by mistake, let us know). Please only comment if it adds context to the issue. If you want to express that you have the same problem, use the upvote 👍 on the issue description or subscribe to the issue for updates. Thanks!
Environment
System: OS: Windows 11 10.0.22631 CPU: (12) x64 13th Gen Intel(R) Core(TM) i7-1355U Memory: 2.92 GB / 15.72 GB Binaries: Node: 20.8.1 - C:\Program Files\nodejs\node.EXE npm: 10.1.0 - C:\Program Files\nodejs\npm.CMD Browsers: Edge: Chromium (123.0.2420.97) Internet Explorer: 11.0.22621.3527 npmPackages: @auth/core: ^0.31.0 => 0.31.0 @auth/sveltekit: ^1.1.0 => 1.1.0
Reproduction URL
https://github.com/stephendewyer/artintechservices/blob/main/src/routes/login-client/%2Bpage.svelte
Describe the issue
I am creating a custom signin page for a project. The signIn function from @auth/sveltekit/client is returning an object that is always status = 200 and ok = true even when the client submits invalid credentials. As a result, I am unable to show users feedback after they submit their credentials. I've tried to find a workaround to no avail. In previous @auth/sveltekit versions (and earlier SvelteKit versions), the signIn function would return status = 400 and ok = false if the credentials submitted by the user were invalid.
How to reproduce
+page.svelte:
auth.js
hooks.server.js
Expected behavior
The signIn function in login-client+page.svelte should return an object with status = 400 and ok = false if the user submits invalid credentials.