implement auth error page and moved auth-related pages to /auth path
This commit is contained in:
@@ -143,13 +143,13 @@ export default function HomePage() {
|
||||
headers: { 'Content-Type': 'application/json' },
|
||||
body: JSON.stringify({ prompt: aiPrompt })
|
||||
})
|
||||
|
||||
|
||||
if (res.status === 401) {
|
||||
alert('Please sign in to use AI features.')
|
||||
setAiLoading(false)
|
||||
return
|
||||
}
|
||||
|
||||
|
||||
const data = await res.json()
|
||||
|
||||
if (Array.isArray(data) && data.length > 0) {
|
||||
@@ -254,7 +254,7 @@ export default function HomePage() {
|
||||
Sign in to unlock AI-powered calendar features
|
||||
</div>
|
||||
<Button variant="outline" size="sm" asChild>
|
||||
<a href="/signin">Sign In</a>
|
||||
<a href="/auth/signin">Sign In</a>
|
||||
</Button>
|
||||
</div>
|
||||
)}
|
||||
|
||||
Reference in New Issue
Block a user