Think it might be ready to deploy. I'm sure there are a lot of bugs, but I at least am no longe finding them
This commit is contained in:
@ -1,7 +1,7 @@
|
||||
'use client';
|
||||
import { createClient } from '@/utils/supabase';
|
||||
import type { Profile, Result } from '@/utils/supabase';
|
||||
import { getUser, getOriginalProfile, getSignedUrl } from '@/lib/hooks';
|
||||
import { getUser, getProfileWithAvatar, getSignedUrl } from '@/lib/hooks';
|
||||
|
||||
export type UserWithStatus = {
|
||||
id?: string;
|
||||
@ -115,7 +115,7 @@ export const updateStatuses = async (
|
||||
): Promise<Result<void>> => {
|
||||
try {
|
||||
const supabase = createClient();
|
||||
const profileResponse = await getOriginalProfile();
|
||||
const profileResponse = await getProfileWithAvatar();
|
||||
if (!profileResponse.success) throw new Error('Not authenticated!');
|
||||
const user = profileResponse.data;
|
||||
|
||||
@ -155,7 +155,7 @@ export const updateUserStatus = async (
|
||||
): Promise<Result<void>> => {
|
||||
try {
|
||||
const supabase = createClient();
|
||||
const profileResponse = await getOriginalProfile();
|
||||
const profileResponse = await getProfileWithAvatar();
|
||||
if (!profileResponse.success)
|
||||
throw new Error(`Not authenticated! ${profileResponse.error}`);
|
||||
const userProfile = profileResponse.data;
|
||||
|
Reference in New Issue
Block a user