Created
March 13, 2013 23:29
-
-
Save gabrielhpugliese/5157484 to your computer and use it in GitHub Desktop.
Reset Session context in hot code push
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if (Meteor._reload) { | |
Meteor._reload.onMigrate('session', function() { | |
return [true, { | |
keys : [] | |
}]; | |
}); | |
(function() { | |
var migrationData = Meteor._reload.migrationData('session'); | |
if (migrationData && migrationData.keys) { | |
Session.keys = migrationData.keys; | |
} | |
})(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment