summaryrefslogtreecommitdiff
path: root/app/helpers/tab_helper.rb
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2013-01-24 17:47:09 +0200
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2013-01-24 17:47:09 +0200
commitf6c482c06f48449e7dcff34455b5bbdfbd8f6c7b (patch)
tree5524251aeea0ae6f00a4ecb8775fbf542d98eab5 /app/helpers/tab_helper.rb
parentd9027df5b55f2eb82f1a71e96412c5e802909090 (diff)
downloadgitlab-ce-f6c482c06f48449e7dcff34455b5bbdfbd8f6c7b.tar.gz
User can create group
Diffstat (limited to 'app/helpers/tab_helper.rb')
-rw-r--r--app/helpers/tab_helper.rb7
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)