create-nara 1.0.41 → 1.0.42

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of create-nara might be problematic. Click here for more details.

package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-nara",
3
- "version": "1.0.41",
3
+ "version": "1.0.42",
4
4
  "description": "CLI to scaffold NARA projects",
5
5
  "type": "module",
6
6
  "bin": {
@@ -35,6 +35,14 @@
35
35
  body: JSON.stringify({ email: form.email, password: form.password })
36
36
  });
37
37
 
38
+ // Check if login was successful via redirect (backend returns 302 on success)
39
+ // fetch follows redirects automatically, so we check if we ended up at dashboard
40
+ if (response.redirected || response.url.endsWith('/dashboard')) {
41
+ Toast('Login successful', 'success');
42
+ router.visit('/dashboard');
43
+ return;
44
+ }
45
+
38
46
  // Handle non-JSON responses (server errors returning HTML)
39
47
  const contentType = response.headers.get('content-type');
40
48
  if (!contentType || !contentType.includes('application/json')) {