Changes
Co-authored-by: renee-png <262607627+renee-png@users.noreply.github.com>
This commit is contained in:
co-authored by
renee-png
parent
daaf3ccc70
commit
e3a011cd69
@@ -31,7 +31,7 @@ function getOrigin() {
|
||||
}
|
||||
|
||||
export const createPaymentRequest = createServerFn({ method: "POST" })
|
||||
.middleware([requireSupabaseAuth])
|
||||
.middleware([attachSupabaseAuth, requireSupabaseAuth])
|
||||
.inputValidator(
|
||||
(data: {
|
||||
recipient_name: string;
|
||||
@@ -122,7 +122,7 @@ export const createPaymentRequest = createServerFn({ method: "POST" })
|
||||
});
|
||||
|
||||
export const refreshPaymentStatus = createServerFn({ method: "POST" })
|
||||
.middleware([requireSupabaseAuth])
|
||||
.middleware([attachSupabaseAuth, requireSupabaseAuth])
|
||||
.inputValidator((data: { id: string }) => data)
|
||||
.handler(async ({ data }) => {
|
||||
const { data: row } = await supabaseAdmin
|
||||
@@ -150,7 +150,7 @@ export const refreshPaymentStatus = createServerFn({ method: "POST" })
|
||||
});
|
||||
|
||||
export const markPaymentEmailSent = createServerFn({ method: "POST" })
|
||||
.middleware([requireSupabaseAuth])
|
||||
.middleware([attachSupabaseAuth, requireSupabaseAuth])
|
||||
.inputValidator((data: { id: string }) => data)
|
||||
.handler(async ({ data }) => {
|
||||
await supabaseAdmin
|
||||
@@ -161,7 +161,7 @@ export const markPaymentEmailSent = createServerFn({ method: "POST" })
|
||||
});
|
||||
|
||||
export const cancelPaymentRequest = createServerFn({ method: "POST" })
|
||||
.middleware([requireSupabaseAuth])
|
||||
.middleware([attachSupabaseAuth, requireSupabaseAuth])
|
||||
.inputValidator((data: { id: string }) => data)
|
||||
.handler(async ({ data }) => {
|
||||
await supabaseAdmin
|
||||
|
||||
Reference in New Issue
Block a user