mirror of
https://github.com/wassname/talk.git
synced 2026-08-11 11:27:10 +08:00
Rename UnBan and UnSuspend
This commit is contained in:
@@ -56,7 +56,7 @@ export default {
|
||||
proxy.writeFragment({fragment: userStatusFragment, id: fragmentId, data: updated});
|
||||
}
|
||||
}),
|
||||
UnSuspendUser: ({variables: {input: {id}}}) => ({
|
||||
UnsuspendUser: ({variables: {input: {id}}}) => ({
|
||||
update: (proxy) => {
|
||||
const fragmentId = `User_${id}`;
|
||||
const data = proxy.readFragment({fragment: userStatusFragment, id: fragmentId});
|
||||
@@ -92,7 +92,7 @@ export default {
|
||||
proxy.writeFragment({fragment: userStatusFragment, id: fragmentId, data: updated});
|
||||
}
|
||||
}),
|
||||
UnBanUser: ({variables: {input: {id}}}) => ({
|
||||
UnbanUser: ({variables: {input: {id}}}) => ({
|
||||
update: (proxy) => {
|
||||
const fragmentId = `User_${id}`;
|
||||
const data = proxy.readFragment({fragment: userStatusFragment, id: fragmentId});
|
||||
|
||||
@@ -6,11 +6,11 @@ export default {
|
||||
'SetUserRoleResponse',
|
||||
'ChangeUsernameResponse',
|
||||
'BanUsersResponse',
|
||||
'UnBanUserResponse',
|
||||
'UnbanUserResponse',
|
||||
'SetUserSuspensionStatusResponse',
|
||||
'SetCommentStatusResponse',
|
||||
'SetUsernameStatusResponse',
|
||||
'UnSuspendUserResponse',
|
||||
'UnsuspendUserResponse',
|
||||
'SuspendUserResponse',
|
||||
'CreateCommentResponse',
|
||||
'CreateFlagResponse',
|
||||
|
||||
@@ -179,9 +179,9 @@ export const withSuspendUser = withMutation(
|
||||
|
||||
export const withUnsuspendUser = withMutation(
|
||||
gql`
|
||||
mutation UnSuspendUser($input: UnSuspendUserInput!) {
|
||||
mutation UnsuspendUser($input: UnsuspendUserInput!) {
|
||||
unsuspendUser(input: $input) {
|
||||
...UnSuspendUserResponse
|
||||
...UnsuspendUserResponse
|
||||
}
|
||||
}
|
||||
`, {
|
||||
@@ -275,9 +275,9 @@ export const withBanUser = withMutation(
|
||||
|
||||
export const withUnbanUser = withMutation(
|
||||
gql`
|
||||
mutation UnBanUser($input: UnBanUserInput!) {
|
||||
mutation UnbanUser($input: UnbanUserInput!) {
|
||||
unbanUser(input: $input) {
|
||||
...UnBanUserResponse
|
||||
...UnbanUserResponse
|
||||
}
|
||||
}
|
||||
`, {
|
||||
|
||||
@@ -1314,7 +1314,7 @@ input BanUserInput {
|
||||
message: String!
|
||||
}
|
||||
|
||||
input UnBanUserInput {
|
||||
input UnbanUserInput {
|
||||
id: ID!
|
||||
}
|
||||
|
||||
@@ -1322,7 +1322,7 @@ type BanUsersResponse implements Response {
|
||||
errors: [UserError!]
|
||||
}
|
||||
|
||||
type UnBanUserResponse implements Response {
|
||||
type UnbanUserResponse implements Response {
|
||||
errors: [UserError!]
|
||||
}
|
||||
|
||||
@@ -1336,13 +1336,13 @@ type SuspendUserResponse implements Response {
|
||||
errors: [UserError!]
|
||||
}
|
||||
|
||||
input UnSuspendUserInput {
|
||||
input UnsuspendUserInput {
|
||||
id: ID!
|
||||
}
|
||||
|
||||
# UnSuspendUserResponse is the response returned with possibly some
|
||||
# UnsuspendUserResponse is the response returned with possibly some
|
||||
# errors relating to the suspend action attempt.
|
||||
type UnSuspendUserResponse implements Response {
|
||||
type UnsuspendUserResponse implements Response {
|
||||
|
||||
# An array of errors relating to the mutation that occurred.
|
||||
errors: [UserError!]
|
||||
@@ -1396,7 +1396,7 @@ type RootMutation {
|
||||
|
||||
# Sets the suspension status on a given user. Requires the `MODERATOR` role.
|
||||
# Mutation is restricted.
|
||||
unsuspendUser(input: UnSuspendUserInput!): UnSuspendUserResponse
|
||||
unsuspendUser(input: UnsuspendUserInput!): UnsuspendUserResponse
|
||||
|
||||
# Sets the ban status on a given user. Requires the `MODERATOR` role.
|
||||
# Mutation is restricted.
|
||||
@@ -1404,7 +1404,7 @@ type RootMutation {
|
||||
|
||||
# Sets the ban status on a given user. Requires the `MODERATOR` role.
|
||||
# Mutation is restricted.
|
||||
unbanUser(input: UnBanUserInput!): UnBanUserResponse
|
||||
unbanUser(input: UnbanUserInput!): UnbanUserResponse
|
||||
|
||||
# Sets the username status on a given user to `APPROVED`. Requires the
|
||||
# `MODERATOR` role. Mutation is restricted.
|
||||
|
||||
Reference in New Issue
Block a user