diff options
author | Chocobozzz <florian.bigard@gmail.com> | 2017-02-16 19:24:34 +0100 |
---|---|---|
committer | Chocobozzz <florian.bigard@gmail.com> | 2017-02-16 19:24:34 +0100 |
commit | 5d67f289df4a68e35ad7e0af3c601c7db0dc7586 (patch) | |
tree | e29d74e65161cc7a0fd88a48da5579e790c5bd62 /server/models/user.js | |
parent | 4793c343fd3cde3c6282ed0fb38e039b4276de0e (diff) | |
download | PeerTube-5d67f289df4a68e35ad7e0af3c601c7db0dc7586.tar.gz PeerTube-5d67f289df4a68e35ad7e0af3c601c7db0dc7586.tar.zst PeerTube-5d67f289df4a68e35ad7e0af3c601c7db0dc7586.zip |
Server: add unique to unique indexes
Diffstat (limited to 'server/models/user.js')
-rw-r--r-- | server/models/user.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/server/models/user.js b/server/models/user.js index 36ed723cc..6cb9eec3f 100644 --- a/server/models/user.js +++ b/server/models/user.js | |||
@@ -40,7 +40,8 @@ module.exports = function (sequelize, DataTypes) { | |||
40 | { | 40 | { |
41 | indexes: [ | 41 | indexes: [ |
42 | { | 42 | { |
43 | fields: [ 'username' ] | 43 | fields: [ 'username' ], |
44 | unique: true | ||
44 | } | 45 | } |
45 | ], | 46 | ], |
46 | classMethods: { | 47 | classMethods: { |