Commit 067ece54 authored by Martin Santangelo's avatar Martin Santangelo

(fix) comment vote counter is a string

parent 32389e01
......@@ -206,7 +206,7 @@ export default class BaseModel {
this['thumbs:' + direction + ':user_guids'] = [sessionService.guid, ...guids];
}
this['thumbs:' + direction + ':count'] += delta;
this['thumbs:' + direction + ':count'] = parseInt(this['thumbs:' + direction + ':count'], 10) + delta;
const params = this.getClientMetadata();
......@@ -220,7 +220,7 @@ export default class BaseModel {
} else {
this['thumbs:' + direction + ':user_guids'] = [sessionService.guid, ...guids];
}
this['thumbs:' + direction + ':count'] -= delta;
this['thumbs:' + direction + ':count'] = parseInt(this['thumbs:' + direction + ':count'], 10) - delta;
throw err;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment