Rename UnBan and UnSuspend

This commit is contained in:
Chi Vinh Le
2018-01-08 14:43:14 +01:00
parent c07ec23a20
commit 717d5e6566
4 changed files with 15 additions and 15 deletions
+2 -2
View File
@@ -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});
+2 -2
View File
@@ -6,11 +6,11 @@ export default {
'SetUserRoleResponse',
'ChangeUsernameResponse',
'BanUsersResponse',
'UnBanUserResponse',
'UnbanUserResponse',
'SetUserSuspensionStatusResponse',
'SetCommentStatusResponse',
'SetUsernameStatusResponse',
'UnSuspendUserResponse',
'UnsuspendUserResponse',
'SuspendUserResponse',
'CreateCommentResponse',
'CreateFlagResponse',
+4 -4
View File
@@ -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
}
}
`, {
+7 -7
View File
@@ -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.