diff --git a/express/username-and-password/routes/login.ts b/express/username-and-password/routes/login.ts index 70be285..6823952 100644 --- a/express/username-and-password/routes/login.ts +++ b/express/username-and-password/routes/login.ts @@ -21,7 +21,7 @@ loginRouter.post("/login", async (req, res) => { if (!username || username.length < 3 || username.length > 31 || !/^[a-z0-9_-]+$/.test(username)) { const html = await renderPage({ username_value: username ?? "", - error: "Invalid password" + error: "Invalid username" }); return res.setHeader("Content-Type", "text/html").status(400).send(html); } diff --git a/express/username-and-password/routes/signup.ts b/express/username-and-password/routes/signup.ts index 5e3b266..b386ad0 100644 --- a/express/username-and-password/routes/signup.ts +++ b/express/username-and-password/routes/signup.ts @@ -21,7 +21,7 @@ signupRouter.post("/signup", async (req, res) => { if (!username || username.length < 3 || username.length > 31 || !/^[a-z0-9_-]+$/.test(username)) { const html = await renderPage({ username_value: username ?? "", - error: "Invalid password" + error: "Invalid username" }); return res.setHeader("Content-Type", "text/html").status(400).send(html); } diff --git a/hono/username-and-password/routes/login.ts b/hono/username-and-password/routes/login.ts index 797c66b..431a94c 100644 --- a/hono/username-and-password/routes/login.ts +++ b/hono/username-and-password/routes/login.ts @@ -27,7 +27,7 @@ loginRouter.post("/login", async (c) => { if (!username || username.length < 3 || username.length > 31 || !/^[a-z0-9_-]+$/.test(username)) { const html = await renderPage({ username_value: username ?? "", - error: "Invalid password" + error: "Invalid username" }); return c.html(html, 200); } diff --git a/hono/username-and-password/routes/signup.ts b/hono/username-and-password/routes/signup.ts index a6a6114..2ff2226 100644 --- a/hono/username-and-password/routes/signup.ts +++ b/hono/username-and-password/routes/signup.ts @@ -28,7 +28,7 @@ signupRouter.post("/signup", async (c) => { if (!username || username.length < 3 || username.length > 31 || !/^[a-z0-9_-]+$/.test(username)) { const html = await renderPage({ username_value: username ?? "", - error: "Invalid password" + error: "Invalid username" }); return c.html(html, 200); }