UNPKG

1.31 kBJavaScriptView Raw
1"use strict";
2Object.defineProperty(exports, "__esModule", { value: true });
3var tslib_1 = require("tslib");
4/**
5 * Thrown when ORM cannot get column's type automatically.
6 * Basically, when reflect-metadata is not available or tsconfig is not properly setup.
7 */
8var ColumnTypeUndefinedError = /** @class */ (function (_super) {
9 tslib_1.__extends(ColumnTypeUndefinedError, _super);
10 function ColumnTypeUndefinedError(object, propertyName) {
11 var _this = _super.call(this) || this;
12 _this.name = "ColumnTypeUndefinedError";
13 Object.setPrototypeOf(_this, ColumnTypeUndefinedError.prototype);
14 _this.message = "Column type for " + object.constructor.name + "#" + propertyName + " is not defined and cannot be guessed. " +
15 "Make sure you have turned on an \"emitDecoratorMetadata\": true option in tsconfig.json. " +
16 "Also make sure you have imported \"reflect-metadata\" on top of the main entry file in your application (before any entity imported)." +
17 "If you are using JavaScript instead of TypeScript you must explicitly provide a column type.";
18 return _this;
19 }
20 return ColumnTypeUndefinedError;
21}(Error));
22exports.ColumnTypeUndefinedError = ColumnTypeUndefinedError;
23
24//# sourceMappingURL=ColumnTypeUndefinedError.js.map