mirror of
https://github.com/scratchfoundation/scratch-www.git
synced 2024-11-30 02:56:20 -05:00
Merge pull request #318 from thisandagain/bugfix/316
Fix error in parsing count from updated API route
This commit is contained in:
commit
029a27dcce
1 changed files with 1 additions and 1 deletions
|
@ -100,7 +100,7 @@ var Navigation = React.createClass({
|
||||||
}, function (err, body) {
|
}, function (err, body) {
|
||||||
if (err) return this.setState({'unreadMessageCount': 0});
|
if (err) return this.setState({'unreadMessageCount': 0});
|
||||||
if (body) {
|
if (body) {
|
||||||
var count = parseInt(body.msg_count, this.state.unreadMessageCount);
|
var count = parseInt(body.count, 10);
|
||||||
return this.setState({'unreadMessageCount': count});
|
return this.setState({'unreadMessageCount': count});
|
||||||
}
|
}
|
||||||
}.bind(this));
|
}.bind(this));
|
||||||
|
|
Loading…
Reference in a new issue