mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
Add a dummy rollback, clean up.
This commit is contained in:
parent
e2570a06d2
commit
afcd6b9f53
1 changed files with 8 additions and 1 deletions
|
@ -6,13 +6,16 @@ db = mongojs(Settings.mongo.url, ['users'])
|
||||||
_ = require("underscore")
|
_ = require("underscore")
|
||||||
BSON = db.bson.BSON
|
BSON = db.bson.BSON
|
||||||
|
|
||||||
|
|
||||||
handleExit = () ->
|
handleExit = () ->
|
||||||
console.log('Got signal. Shutting down.')
|
console.log('Got signal. Shutting down.')
|
||||||
|
|
||||||
|
|
||||||
process.on 'SIGINT', handleExit
|
process.on 'SIGINT', handleExit
|
||||||
process.on 'SIGHUP', handleExit
|
process.on 'SIGHUP', handleExit
|
||||||
|
|
||||||
module.exports.migrate = (client, done=()->) ->
|
|
||||||
|
exports.migrate = (client, done=()->) ->
|
||||||
patch = {
|
patch = {
|
||||||
$set: {
|
$set: {
|
||||||
features: {
|
features: {
|
||||||
|
@ -30,3 +33,7 @@ module.exports.migrate = (client, done=()->) ->
|
||||||
db.users.update {}, patch, {multi: true}, (err) ->
|
db.users.update {}, patch, {multi: true}, (err) ->
|
||||||
console.log "finished updating all user features"
|
console.log "finished updating all user features"
|
||||||
return done(err)
|
return done(err)
|
||||||
|
|
||||||
|
|
||||||
|
exports.rollback = (client, done) ->
|
||||||
|
done()
|
||||||
|
|
Loading…
Reference in a new issue