lib/assets/javascripts/up/navigation.js.coffee in upjs-rails-0.7.7 vs lib/assets/javascripts/up/navigation.js.coffee in upjs-rails-0.7.8

- old
+ new

@@ -38,10 +38,11 @@ values = aliases.split(' ') urls = urls.concat(values) urls.map normalizeUrl urlSet = (urls) -> + urls = u.compact(urls) matches = (testUrl) -> if testUrl.substr(-1) == '*' doesMatchPrefix(testUrl.slice(0, -1)) else @@ -166,16 +167,16 @@ @method [up-current] @ujs ### up.bus.on 'fragment:ready', -> + # If a new fragment is inserted, it's likely to be the result + # of the active action. So we can remove the active marker. + unmarkActive() # When a fragment is ready it might either have brought a location change # with it, or it might have opened a modal / popup which we consider # to be secondary location sources (the primary being the browser's # location bar). - unmarkActive() - # If a new fragment is inserted, it's likely to be the result - # to the active action. So we can remove the active marker. locationChanged() up.bus.on 'fragment:destroy', ($fragment) -> # If the destroyed fragment is a modal or popup container # this changes which URLs we consider currents.