summaryrefslogtreecommitdiff
path: root/models/match.js
diff options
context:
space:
mode:
authorschneefux <schneefux+commit@schneefux.xyz>2017-04-10 16:47:39 +0200
committerschneefux <schneefux+commit@schneefux.xyz>2017-04-10 16:47:39 +0200
commit22afb45c9f9b13b13b5899fc5d66e98259260267 (patch)
tree15b2f97caafe60d3c265696af96ad0cfb371f8b5 /models/match.js
parentb3ba4b3da3bf2d1e7b75ca3d0e68ae7fe08acef4 (diff)
downloadorm-22afb45c9f9b13b13b5899fc5d66e98259260267.tar.gz
orm-22afb45c9f9b13b13b5899fc5d66e98259260267.zip
import schema
Diffstat (limited to 'models/match.js')
-rw-r--r--models/match.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/models/match.js b/models/match.js
index 0b9f6d9..7efd63b 100644
--- a/models/match.js
+++ b/models/match.js
@@ -19,7 +19,8 @@ module.exports = function(sequelize, DataTypes) {
},
created_at: {
type: DataTypes.TIME,
- allowNull: false
+ allowNull: false,
+ defaultValue: sequelize.literal('CURRENT_TIMESTAMP')
},
duration: {
type: DataTypes.INTEGER(5).UNSIGNED,