Skip to content

Commit

Permalink
chore: fix some types with TS v4.9
Browse files Browse the repository at this point in the history
  • Loading branch information
marcj committed Feb 23, 2023
1 parent ade205c commit e9dce6a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/type/src/serializer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -392,7 +392,7 @@ export class TemplateState {
return !!this.validation;
}

withValidation(validation: typeof this['validation']): this {
withValidation(validation: this['validation']): this {
this.validation = validation;
return this;
}
Expand Down
2 changes: 1 addition & 1 deletion packages/type/tests/complex-query.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ export class BaseQuery<T extends OrmEntity> {
}

withGroupConcat<K extends FieldName<T>, AS extends string>(field: K, as?: AS): Replace<this, Resolve<this> & { [C in [AS] as `${AS}`]: T[K][] }> {
return this.aggregateField(field, 'group_concat', as);
return this.aggregateField(field, 'group_concat', as) as any;
}

withCount<K extends FieldName<T>, AS extends string>(field: K, as?: AS): Replace<this, Resolve<this> & { [K in [AS] as `${AS}`]: number }> {
Expand Down

0 comments on commit e9dce6a

Please sign in to comment.