diff options
-rw-r--r-- | client/src/components/AdminLogin.test.tsx | 2 | ||||
-rw-r--r-- | client/src/components/AdminLogin.tsx | 1 | ||||
-rw-r--r-- | client/src/components/GuestLogin.tsx | 1 | ||||
-rw-r--r-- | client/src/components/Registry.tsx | 1 | ||||
-rw-r--r-- | client/src/components/RsvpForm.tsx | 1 | ||||
-rw-r--r-- | client/src/components/Schedule.tsx | 1 | ||||
-rw-r--r-- | client/src/mocks/worker.ts | 4 | ||||
-rw-r--r-- | client/vite-env.d.ts (renamed from client/src/vite-env.d.ts) | 0 | ||||
-rw-r--r-- | server/admin/handler.go | 2 | ||||
-rw-r--r-- | server/admin/store.go | 2 |
10 files changed, 8 insertions, 7 deletions
diff --git a/client/src/components/AdminLogin.test.tsx b/client/src/components/AdminLogin.test.tsx index feffadf..58368af 100644 --- a/client/src/components/AdminLogin.test.tsx +++ b/client/src/components/AdminLogin.test.tsx @@ -1,6 +1,6 @@ import '@testing-library/jest-dom'; import React from 'react'; -import { fireEvent, screen } from '@testing-library/react'; +import { fireEvent } from '@testing-library/react'; import { userEvent } from '@testing-library/user-event'; import { describe, expect, it } from 'vitest'; import { createMemoryRouter, RouterProvider } from 'react-router-dom'; diff --git a/client/src/components/AdminLogin.tsx b/client/src/components/AdminLogin.tsx index b69e493..a4fce8d 100644 --- a/client/src/components/AdminLogin.tsx +++ b/client/src/components/AdminLogin.tsx @@ -72,6 +72,7 @@ function GuestLogin() { alignItems: 'center', mt: 16, p: 2, + borderRadius: 2, }} > <Typography variant="h6">Admin Login</Typography> diff --git a/client/src/components/GuestLogin.tsx b/client/src/components/GuestLogin.tsx index d0270cb..2f5a3eb 100644 --- a/client/src/components/GuestLogin.tsx +++ b/client/src/components/GuestLogin.tsx @@ -72,6 +72,7 @@ function GuestLogin() { alignItems: 'center', mt: 16, p: 2, + borderRadius: 2, }} > <Typography variant="h6">Guest Login</Typography> diff --git a/client/src/components/Registry.tsx b/client/src/components/Registry.tsx index 7a3d1ad..3414e9d 100644 --- a/client/src/components/Registry.tsx +++ b/client/src/components/Registry.tsx @@ -24,6 +24,7 @@ function Registry() { flexDirection: 'column', px: 1, pb: 2, + borderRadius: 2, }} > <p style={{ textAlign: 'center' }}> diff --git a/client/src/components/RsvpForm.tsx b/client/src/components/RsvpForm.tsx index 8dc105a..eae34c3 100644 --- a/client/src/components/RsvpForm.tsx +++ b/client/src/components/RsvpForm.tsx @@ -125,6 +125,7 @@ function RsvpForm() { px: 2, pb: 2, mt: { xs: 10, md: 16 }, + borderRadius: 2, }} > <Grid container spacing={2}> diff --git a/client/src/components/Schedule.tsx b/client/src/components/Schedule.tsx index c3651fd..9df59b6 100644 --- a/client/src/components/Schedule.tsx +++ b/client/src/components/Schedule.tsx @@ -21,6 +21,7 @@ function Schedule() { sx={{ width: { xs: '90%', md: 512 }, px: 2, + borderRadius: 2, }} > <div style={{ display: 'flex', alignItems: 'center' }}> diff --git a/client/src/mocks/worker.ts b/client/src/mocks/worker.ts deleted file mode 100644 index 0a56427..0000000 --- a/client/src/mocks/worker.ts +++ /dev/null @@ -1,4 +0,0 @@ -import { setupWorker } from 'msw/browser'; -import { handlers } from './handlers'; - -export const worker = setupWorker(...handlers); diff --git a/client/src/vite-env.d.ts b/client/vite-env.d.ts index 72eb128..72eb128 100644 --- a/client/src/vite-env.d.ts +++ b/client/vite-env.d.ts diff --git a/server/admin/handler.go b/server/admin/handler.go index b05fc88..fa2dfb4 100644 --- a/server/admin/handler.go +++ b/server/admin/handler.go @@ -59,7 +59,7 @@ func (adminHandler *AdminHandler) logIn(request *http.Request) ([]byte, *appErro } _, err = adminHandler.adminStore.Find(requestAdmin) if err != nil { - return []byte{}, &appError{err, "{ \"message\": \"Admin not found\" }", + return []byte{}, &appError{err, "{ \"message\": \"Invalid username or password\" }", http.StatusUnauthorized} } expirationTime := adminHandler.setExpirationTime() diff --git a/server/admin/store.go b/server/admin/store.go index c466b95..f36b342 100644 --- a/server/admin/store.go +++ b/server/admin/store.go @@ -30,7 +30,7 @@ func (store Store) Find(requestAdmin Admin) (Admin, error) { if found { return admin, nil } - return Admin{}, errors.New("Admin not found") + return Admin{}, errors.New("invalid username or password") } func createAdmin(requestAdmin Admin, adminRows pgx.Rows) (Admin, bool) { |