From bd1e1ffe81597a9fd1352c8a744bcff5973356ce Mon Sep 17 00:00:00 2001 From: Devin Howard Date: Wed, 13 Apr 2016 10:32:27 +0800 Subject: [PATCH 1/2] ruby gemset --- .ruby-gemset | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.ruby-gemset b/.ruby-gemset index f4597680..ea3bcc43 100644 --- a/.ruby-gemset +++ b/.ruby-gemset @@ -1 +1 @@ -metamaps_gen002 +metamaps From 298940695458268ffcbc543aa2327f87265dc24f Mon Sep 17 00:00:00 2001 From: Devin Howard Date: Wed, 15 Jun 2016 12:17:32 +0800 Subject: [PATCH 2/2] fix truncate bug when map desc is nil --- app/helpers/maps_helper.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/helpers/maps_helper.rb b/app/helpers/maps_helper.rb index 169ee4b9..8a48ab33 100644 --- a/app/helpers/maps_helper.rb +++ b/app/helpers/maps_helper.rb @@ -8,7 +8,7 @@ module MapsHelper map['id'] = m.id map['label'] = m.name map['value'] = m.name - map['description'] = m.desc.truncate(30) + map['description'] = m.desc.try(:truncate, 30) map['permission'] = m.permission map['topicCount'] = m.topics.count map['synapseCount'] = m.synapses.count