Skip to content

Commit

Permalink
fix(repository): fix compilation errors with TypeScript 3.7.2
Browse files Browse the repository at this point in the history
  • Loading branch information
raymondfeng committed Nov 5, 2019
1 parent 9bd5cf0 commit d62612d
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ export function createHasManyInclusionResolver<

return async function fetchHasManyModels(
entities: Entity[],
inclusion: Inclusion<Entity>,
inclusion: Inclusion<AnyObject>,
options?: Options,
): Promise<((Target & TargetRelations)[] | undefined)[]> {
if (!entities.length) return [];
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ export function createHasOneInclusionResolver<

return async function fetchHasOneModel(
entities: Entity[],
inclusion: Inclusion<Entity>,
inclusion: Inclusion<AnyObject>,
options?: Options,
): Promise<((Target & TargetRelations) | undefined)[]> {
if (!entities.length) return [];
Expand Down
4 changes: 2 additions & 2 deletions packages/repository/src/relations/relation.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// This file is licensed under the MIT License.
// License text available at https://opensource.org/licenses/MIT

import {Options} from '../common-types';
import {AnyObject, Options} from '../common-types';
import {Entity} from '../model';
import {Inclusion} from '../query';
import {TypeResolver} from '../type-resolver';
Expand Down Expand Up @@ -126,7 +126,7 @@ export type InclusionResolver<S extends Entity, T extends Entity> = (
/**
* Inclusion requested by the user (e.g. scope constraints to apply).
*/
inclusion: Inclusion,
inclusion: Inclusion<AnyObject>,
/**
* Generic options object, e.g. carrying the Transaction object.
*/
Expand Down

0 comments on commit d62612d

Please sign in to comment.