Compare commits
3 commits
75837fa2f7
...
2f8f5d2750
Author | SHA1 | Date | |
---|---|---|---|
|
2f8f5d2750 | ||
|
beac31c9ae | ||
|
c16c43f2d4 |
4 changed files with 13 additions and 3 deletions
|
@ -30,6 +30,8 @@ In the `.env` file that've you copied from `.env.example, you'll need to change
|
|||
|
||||
For production use, make sure to follow all instructions needed from https://supabase.com/docs/guides/self-hosting/docker.
|
||||
|
||||
> SMTP is required for email verification, as a code is required. The end-user is not allowed to login yet until their email is verified.
|
||||
|
||||
### Allowing Account Deletion
|
||||
When an end-user wants to delete their account, they'll be directed to `/api/account/delete`. This API requires that a function already exist in your Supabase project called `delete_user()`.
|
||||
|
||||
|
|
|
@ -1,9 +1,11 @@
|
|||
---
|
||||
const { Title } = Astro.props
|
||||
import { ViewTransitions } from 'astro:transitions';
|
||||
---
|
||||
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=2.2" />
|
||||
<title>{Title}</title>
|
||||
</head>
|
||||
</head>
|
||||
<ViewTransitions />
|
|
@ -22,7 +22,7 @@ export const POST: APIRoute = async ({ request, redirect }) => {
|
|||
plan: "Free",
|
||||
theme: "Dark",
|
||||
color_scheme: "Green",
|
||||
beta: true
|
||||
beta: true,
|
||||
}
|
||||
},
|
||||
email,
|
||||
|
|
|
@ -10,13 +10,19 @@ let { data: subs } = await supabase
|
|||
.select("*")
|
||||
.eq('UserSubscribed', id)
|
||||
.eq('Id', CreatorId)
|
||||
|
||||
if (subs[0] === undefined) {
|
||||
var Subbed = false
|
||||
} else {
|
||||
var Subbed = true
|
||||
}
|
||||
---
|
||||
|
||||
<Base Title="Supabase Demo">
|
||||
<div style="display: flex; justify-content: space-between; align-items: center;">
|
||||
<p style="font-size: 18px; font-weight: bold;">Vsause</p>
|
||||
<div>
|
||||
{subs[0].Subscribed ?
|
||||
{Subbed ?
|
||||
<a style="font-size: 14px;" href={"/api/account/subscription/remove?=" + 'C6nSFpj9HTCZ5t-N3Rm3-HA'}>Unsubscribe</a>
|
||||
:
|
||||
<a style="font-size: 14px;" href={"/api/account/subscription/add?=" + 'C6nSFpj9HTCZ5t-N3Rm3-HA'}>Subscribe</a>
|
||||
|
|
Loading…
Reference in a new issue