Skip to content

Commit

Permalink
fix: use custom decorator on column have a property descriptor (#1070)
Browse files Browse the repository at this point in the history
  • Loading branch information
caolvchong authored Jan 3, 2022
1 parent f16baa4 commit 7ce03de
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/model/column/column.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,12 @@ export function Column(...args: any[]): Function | void {
}

return (target: any, propertyName: string, propertyDescriptor?: PropertyDescriptor) => {
annotate(target, propertyName, propertyDescriptor, args[0]);
annotate(
target,
propertyName,
propertyDescriptor ?? Object.getOwnPropertyDescriptor(target, propertyName),
args[0]
);
};
}

Expand Down

0 comments on commit 7ce03de

Please sign in to comment.