Subscription finally working!
This commit is contained in:
@ -30,14 +30,12 @@ export const getRecentUsersWithStatuses = async (): Promise<
|
||||
|
||||
const { data, error } = (await supabase
|
||||
.from('statuses')
|
||||
.select(
|
||||
`
|
||||
.select(`
|
||||
user:profiles!user_id(*),
|
||||
status,
|
||||
created_at,
|
||||
updated_by:profiles!updated_by_id(*)
|
||||
`,
|
||||
)
|
||||
`)
|
||||
.gte('created_at', oneDayAgo.toISOString())
|
||||
.order('created_at', { ascending: false })) as {
|
||||
data: UserWithStatus[];
|
||||
@ -172,6 +170,7 @@ export const updateUserStatus = async (
|
||||
user: userProfile,
|
||||
status: insertedStatus.status,
|
||||
created_at: insertedStatus.created_at,
|
||||
updated_by: userProfile,
|
||||
};
|
||||
|
||||
await broadcastStatusUpdates([userStatus]);
|
||||
|
Reference in New Issue
Block a user