fix: changed user type to AuthUser in user-settings resolver
This commit is contained in:
@@ -8,6 +8,7 @@ import { throwErr } from 'src/utils';
|
|||||||
import { UserSettings } from './user-settings.model';
|
import { UserSettings } from './user-settings.model';
|
||||||
import { UserSettingsService } from './user-settings.service';
|
import { UserSettingsService } from './user-settings.service';
|
||||||
import { PubSubService } from 'src/pubsub/pubsub.service';
|
import { PubSubService } from 'src/pubsub/pubsub.service';
|
||||||
|
import { AuthUser } from 'src/types/AuthUser';
|
||||||
|
|
||||||
@Resolver()
|
@Resolver()
|
||||||
export class UserSettingsResolver {
|
export class UserSettingsResolver {
|
||||||
@@ -23,7 +24,7 @@ export class UserSettingsResolver {
|
|||||||
})
|
})
|
||||||
@UseGuards(GqlAuthGuard)
|
@UseGuards(GqlAuthGuard)
|
||||||
async createUserSettings(
|
async createUserSettings(
|
||||||
@GqlUser() user: User,
|
@GqlUser() user: AuthUser,
|
||||||
@Args({
|
@Args({
|
||||||
name: 'properties',
|
name: 'properties',
|
||||||
description: 'Stringified JSON settings object',
|
description: 'Stringified JSON settings object',
|
||||||
@@ -42,7 +43,7 @@ export class UserSettingsResolver {
|
|||||||
})
|
})
|
||||||
@UseGuards(GqlAuthGuard)
|
@UseGuards(GqlAuthGuard)
|
||||||
async updateUserSettings(
|
async updateUserSettings(
|
||||||
@GqlUser() user: User,
|
@GqlUser() user: AuthUser,
|
||||||
@Args({
|
@Args({
|
||||||
name: 'properties',
|
name: 'properties',
|
||||||
description: 'Stringified JSON settings object',
|
description: 'Stringified JSON settings object',
|
||||||
|
|||||||
Reference in New Issue
Block a user