Skip to content

Commit 56ea57c

Browse files
committed
eslint/prettier fixes
1 parent 52d67fa commit 56ea57c

File tree

3 files changed

+14
-14
lines changed

3 files changed

+14
-14
lines changed

src/type/definition.js

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -981,8 +981,8 @@ export type GraphQLArgument = {|
981981
description: ?string,
982982
type: GraphQLInputType,
983983
defaultValue: mixed,
984-
isDeprecated?:boolean,
985-
deprecationReason?: ? string,
984+
isDeprecated?: boolean,
985+
deprecationReason?: ?string,
986986
extensions: ?ReadOnlyObjMap<mixed>,
987987
astNode: ?InputValueDefinitionNode,
988988
|};
@@ -1529,9 +1529,9 @@ function defineInputFieldMap(
15291529
`${config.name}.${fieldName} field has a resolve property, but Input Types cannot define resolvers.`,
15301530
);
15311531
devAssert(
1532-
!fieldConfig.hasOwnProperty('isDeprecated'),
1533-
`${config.name}.${fieldName} should provide "deprecationReason" `+
1534-
'instead of "isDeprecated".',
1532+
!('isDeprecated' in fieldConfig),
1533+
`${config.name}.${fieldName} should provide "deprecationReason" ` +
1534+
'instead of "isDeprecated".',
15351535
);
15361536

15371537
return {
@@ -1559,7 +1559,7 @@ export type GraphQLInputFieldConfig = {|
15591559
description?: ?string,
15601560
type: GraphQLInputType,
15611561
defaultValue?: mixed,
1562-
deprecationReason?: ? string,
1562+
deprecationReason?: ?string,
15631563
extensions?: ?ReadOnlyObjMapLike<mixed>,
15641564
astNode?: ?InputValueDefinitionNode,
15651565
|};
@@ -1571,7 +1571,7 @@ export type GraphQLInputField = {|
15711571
description: ?string,
15721572
type: GraphQLInputType,
15731573
defaultValue: mixed,
1574-
isDeprecated?:boolean,
1574+
isDeprecated?: boolean,
15751575
deprecationReason?: ?string,
15761576
extensions: ?ReadOnlyObjMap<mixed>,
15771577
astNode: ?InputValueDefinitionNode,

src/type/introspection.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -294,11 +294,11 @@ export const __Type = new GraphQLObjectType({
294294
defaultValue: false,
295295
},
296296
},
297-
resolve(type, {includeDeprecated}) {
297+
resolve(type, { includeDeprecated }) {
298298
if (isInputObjectType(type)) {
299-
let values=objectValues(type.getFields());
299+
let values = objectValues(type.getFields());
300300
if (!includeDeprecated) {
301-
values=values.filter(value => !value.deprecationReason);
301+
values = values.filter(value => !value.deprecationReason);
302302
}
303303
return values;
304304
}
@@ -334,11 +334,11 @@ export const __Field = new GraphQLObjectType({
334334
},
335335
},
336336
// resolve: field => field.args || [],
337-
resolve(field, {includeDeprecated}) {
338-
let args=field.args||[];
337+
resolve(field, { includeDeprecated }) {
338+
let args = field.args || [];
339339

340340
if (!includeDeprecated) {
341-
args=args.filter(arg => !arg.deprecationReason);
341+
args = args.filter(arg => !arg.deprecationReason);
342342
}
343343

344344
return args;

src/utilities/__tests__/buildASTSchema-test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -799,7 +799,7 @@ describe('Schema Builder', () => {
799799
`);
800800

801801
expect(printAllASTNodes(someScalar)).to.equal(scalarSDL);
802-
const rootFields=assertObjectType(schema.getType('Query')).getFields();
802+
const rootFields = assertObjectType(schema.getType('Query')).getFields();
803803

804804
expect(rootFields.field2.isDeprecated).to.equal(true);
805805
expect(rootFields.field2.deprecationReason).to.equal('Because I said so');

0 commit comments

Comments
 (0)