Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

do not assume list is integer indexed

  • Loading branch information...
commit abe551d11a784297d89866956f0806b8a74aabd5 1 parent e68a267
Steven Gravell authored
Showing with 6 additions and 3 deletions.
  1. +6 −3 priv/js/renderer.js
View
9 priv/js/renderer.js
@@ -103,11 +103,14 @@ var RENDERER = (function() {
}
else
{
- d.append( render_json_val(list[0]) );
- for(var i = 1 ; i < list.length; ++i)
+ var first = true;
+ for(var i in list)
{
- d.append(', ');
+ if(!first) {
+ d.append(', ');
+ }
d.append( render_json_val(list[i]) );
+ first = false;
}
d.append(etag);
return d;
Please sign in to comment.
Something went wrong with that request. Please try again.