Skip to content

Commit

Permalink
fix(core): deprecate wrappedReference and IdentifiedReference
Browse files Browse the repository at this point in the history
Use `Ref` and `ref` instead, the long form aliases will be removed in v6.
  • Loading branch information
B4nan committed May 5, 2023
1 parent ff00110 commit ab79832
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions packages/core/src/entity/Reference.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import type { LockMode } from '../enums';
import { helper, wrap } from './wrap';
import { Utils } from '../utils/Utils';

/** @deprecated use `Ref` instead, `IdentifiedReference` type will be removed in v6 */
export type IdentifiedReference<T, PK extends keyof T | unknown = PrimaryProperty<T>> = true extends IsUnknown<PK> ? Reference<T> : ({ [K in Cast<PK, keyof T>]: T[K] } & Reference<T>);

export class Reference<T> {
Expand Down
1 change: 1 addition & 0 deletions packages/core/src/typings.ts
Original file line number Diff line number Diff line change
Expand Up @@ -264,6 +264,7 @@ export interface EntityProperty<T = any> {
precision?: number;
scale?: number;
reference: ReferenceType;
/** @deprecated use `ref` instead, `wrappedReference` option will be removed in v6 */
wrappedReference?: boolean;
fieldNames: string[];
fieldNameRaw?: string;
Expand Down

0 comments on commit ab79832

Please sign in to comment.