diff options
-rw-r--r-- | web/cobrands/highwaysengland/assets.js | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/web/cobrands/highwaysengland/assets.js b/web/cobrands/highwaysengland/assets.js index d8ba8b6ac..8e50ed396 100644 --- a/web/cobrands/highwaysengland/assets.js +++ b/web/cobrands/highwaysengland/assets.js @@ -63,9 +63,15 @@ fixmystreet.assets.add(defaults, { found: function(layer, feature) { // If the road isn't in area 7 then we want to show the not found message. fixmystreet.message_controller.road_found(layer, feature, function(feature) { - $('#js-top-message').show(); - $('#form_category_row').show(); - return feature.attributes.area_name === 'Area 7'; + if (feature.attributes.area_name === 'Area 7') { + $('#js-top-message').show(); + $('#form_category_row').show(); + return true; + } else { + $('#js-top-message').hide(); + $('#form_category_row').hide(); + return false; + } }, '#js-not-area7-road'); }, not_found: function(layer) { |