Skip to content

Commit 28d4e8d

Browse files
committed
fix(Flow): Relax flowtype defs for upcoming mongoose declarations.
See screenshots from: https://twitter.com/nodkz/status/901183624950710272
1 parent 89edea5 commit 28d4e8d

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/composeWithMongoose.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ import type {
1616
} from './definition';
1717

1818
export function composeWithMongoose(
19-
model: MongooseModelT,
19+
model: Object, // MongooseModelT, TODO use Model from mongoose_v4.x.x definition when it will be public
2020
opts: TypeConverterOpts = {}
2121
): TypeComposer {
2222
const name: string = (opts && opts.name) || model.modelName;

src/fieldsConverter.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ import typeStorage from './typeStorage';
1717

1818
import type {
1919
MongooseModelT,
20-
MongooseModelSchemaT,
20+
// MongooseModelSchemaT,
2121
MongoosePseudoModelT,
2222
MongooseFieldT,
2323
MongooseFieldMapT,
@@ -187,7 +187,7 @@ export function convertModelToGraphQL(
187187
}
188188

189189
export function convertSchemaToGraphQL(
190-
schema: MongooseModelSchemaT,
190+
schema: Object, // MongooseModelSchemaT, TODO use Model from mongoose_v4.x.x definition when it will be public
191191
typeName: string
192192
): TypeComposer {
193193
if (!typeName) {

0 commit comments

Comments
 (0)