mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-19 07:37:25 +01:00
use model events to handle stats notifications. not perfect, need to
fix handling of "undo exp/gp" operation
This commit is contained in:
@@ -12,7 +12,7 @@ module.exports = function(expressApp, root, derby) {
|
||||
if (err || !user.get()) {
|
||||
return;
|
||||
}
|
||||
scoring.setUser(user);
|
||||
scoring.setModel(model);
|
||||
return scoring.score({
|
||||
direction: 'up'
|
||||
});
|
||||
@@ -27,7 +27,7 @@ module.exports = function(expressApp, root, derby) {
|
||||
if (err || !user.get()) {
|
||||
return;
|
||||
}
|
||||
scoring.setUser(user);
|
||||
scoring.setModel(model);
|
||||
return scoring.score({
|
||||
direction: 'down'
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user