UNPKG

666 BJavaScriptView Raw
1"use strict";
2Object.defineProperty(exports, "__esModule", { value: true });
3exports.AllowNull = void 0;
4const attribute_service_1 = require("../attribute-service");
5function AllowNull(...args) {
6 if (args.length === 1) {
7 const allowNull = args[0];
8 return (target, propertyName) => (0, attribute_service_1.addAttributeOptions)(target, propertyName, { allowNull });
9 }
10 else {
11 const target = args[0];
12 const propertyName = args[1];
13 (0, attribute_service_1.addAttributeOptions)(target, propertyName, {
14 allowNull: true,
15 });
16 }
17}
18exports.AllowNull = AllowNull;
19//# sourceMappingURL=allow-null.js.map
\No newline at end of file