diff --git a/src/geo/ui/legend.js b/src/geo/ui/legend.js
index <HASH>..<HASH> 100644
--- a/src/geo/ui/legend.js
+++ b/src/geo/ui/legend.js
@@ -42,7 +42,7 @@ cdb.geo.ui.LegendItem = cdb.core.View.extend({
   render: function() {
 
     var value;
-
+    this.model.attributes.name = ""+this.model.attributes.name;
     if (this.model.get("type") == 'image' && this.model.get("value")) {
       value = "url( " + this.model.get("value") + ")";
     } else {
makes sure value names as numbers don't evaluate to null, by converting them to strings before templating