diff options
Diffstat (limited to 'app/helpers')
-rw-r--r-- | app/helpers/tab_helper.rb | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/app/helpers/tab_helper.rb b/app/helpers/tab_helper.rb index d52d8af6641..5bd6de896ee 100644 --- a/app/helpers/tab_helper.rb +++ b/app/helpers/tab_helper.rb @@ -39,7 +39,12 @@ module TabHelper # Returns a list item element String def nav_link(options = {}, &block) if path = options.delete(:path) - c, a, _ = path.split('#') + if path.respond_to?(:each) + c = path.map { |p| p.split('#').first } + a = path.map { |p| p.split('#').last } + else + c, a, _ = path.split('#') + end else c = options.delete(:controller) a = options.delete(:action) |