Skip to content

Commit 7a25b33

Browse files
committed
Fix flowtype errors
1 parent ed1d735 commit 7a25b33

File tree

3 files changed

+6
-0
lines changed

3 files changed

+6
-0
lines changed

src/composeWithMongoose.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ export function composeWithMongoose(
3232
prepareFields(typeComposer, opts.fields);
3333
}
3434

35+
// $FlowFixMe
3536
typeComposer.setRecordIdFn(source => (source ? `${source._id}` : ''));
3637

3738
createInputType(typeComposer, opts.inputType);

src/definition.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
/* eslint-disable */
33

44
import type { TypeComposer } from 'graphql-compose';
5+
import type { ProjectionType } from 'graphql-compose/lib/definition';
56
import type { connectionSortMapOpts as _connectionSortMapOpts} from 'graphql-compose-connection/lib/definition';
67
export type connectionSortMapOpts = _connectionSortMapOpts;
78

@@ -100,6 +101,7 @@ export type GraphQLResolveInfo = _GraphQLResolveInfo;
100101
export type ResolverMWResolveFn = _ResolverMWResolveFn;
101102
export type ExtendedResolveParams = ResolveParams & {
102103
query: MongooseQuery,
104+
projection: ProjectionType,
103105
};
104106

105107

@@ -191,6 +193,7 @@ export type filterHelperArgsOpts = {
191193
onlyIndexed?: boolean,
192194
requiredFields?: string | string[],
193195
operators?: filterOperatorsOpts | false,
196+
removeFields?: string | string[],
194197
};
195198

196199
export type filterOperatorNames = 'gt' | 'gte' | 'lt' | 'lte' | 'ne' | 'in[]' | 'nin[]';

src/resolvers/helpers/filter.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -216,4 +216,6 @@ export function addFieldsWithOperator(
216216
description: 'List of fields that can be filtered via operators',
217217
});
218218
}
219+
220+
return operatorsComposer;
219221
}

0 commit comments

Comments
 (0)