aboutsummaryrefslogtreecommitdiff
path: root/src/web/js
diff options
context:
space:
mode:
authorCédric Bonhomme <cedric@cedricbonhomme.org>2016-11-09 00:04:28 +0100
committerCédric Bonhomme <cedric@cedricbonhomme.org>2016-11-09 00:04:28 +0100
commitf8721f803b0f19d1d8cf9031690e193b75bb382c (patch)
tree7223c281a7e828a2b8534cb6905392ef2108c2bd /src/web/js
parentinverse parameters of reduce (diff)
downloadnewspipe-f8721f803b0f19d1d8cf9031690e193b75bb382c.tar.gz
newspipe-f8721f803b0f19d1d8cf9031690e193b75bb382c.tar.bz2
newspipe-f8721f803b0f19d1d8cf9031690e193b75bb382c.zip
Set the initial value of the reduce.
Diffstat (limited to 'src/web/js')
-rw-r--r--src/web/js/components/RightPanel.react.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/web/js/components/RightPanel.react.js b/src/web/js/components/RightPanel.react.js
index 06f871c0..60ef426e 100644
--- a/src/web/js/components/RightPanel.react.js
+++ b/src/web/js/components/RightPanel.react.js
@@ -78,9 +78,9 @@ var PanelMixin = {
items.push(<dd key={key}><Glyphicon glyph="unchecked" /></dd>);
}
} else if (field.type == 'list') {
- items.push(<dd key={key}>{this.props.obj[field.key].reduce(function(concatenatedTag, currentTag) {
- return currentTag.concat(", ", concatenatedTag)
- })}</dd>)
+ items.push(<dd key={key}>{this.props.obj[field.key].reduce(function(previousTag, currentTag) {
+ return currentTag.concat(", ", previousTag)
+ }, "")}</dd>)
} else if (field.type == 'link') {
items.push(<dd key={key}>
<a href={this.props.obj[field.key]}>
bgstack15