Commit af5a5f1d authored by nanahira's avatar nanahira

fix missing unique field

parent 529aa459
......@@ -28,7 +28,8 @@ __decorate([
__metadata("design:type", String)
], Ban.prototype, "name", void 0);
Ban = __decorate([
typeorm_1.Entity()
typeorm_1.Entity(),
typeorm_1.Unique(["ip", "name"])
], Ban);
exports.Ban = Ban;
//# sourceMappingURL=Ban.js.map
\ No newline at end of file
import {Column, Entity, Index, PrimaryGeneratedColumn} from "typeorm";
import {Column, Entity, Index, PrimaryGeneratedColumn, Unique} from "typeorm";
@Entity()
@Unique(["ip", "name"])
export class Ban {
@PrimaryGeneratedColumn({ unsigned: true, type: "bigint" })
id: number;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment