Fix header counters to correctly handle zero
Currently if you set the value to zero the counter is not displayed.pull/21833/head
parent
8940c4e06f
commit
03d60e6af2
|
@ -122,7 +122,9 @@ module.exports = React.createClass({
|
|||
const severity = ev.getContent().severity || "normal";
|
||||
const stateKey = ev.getStateKey();
|
||||
|
||||
if (title && value && severity) {
|
||||
// We want a non-empty title but can accept falsey values (e.g.
|
||||
// zero)
|
||||
if (title && value !== undefined) {
|
||||
counters.push({
|
||||
"title": title,
|
||||
"value": value,
|
||||
|
|
Loading…
Reference in New Issue