Patch #1664 ยป menu_manager_ruby186.patch
lib/redmine/menu_manager.rb Locally Modified (Based On LOCAL) | ||
---|---|---|
130 | 130 |
|
131 | 131 |
# menu item position |
132 | 132 |
if before = options.delete(:before) |
133 |
position = @menu_items.index {|i| i.name == before}
|
|
133 |
position = @menu_items.collect{|i| i.name}.index(before)
|
|
134 | 134 |
elsif after = options.delete(:after) |
135 |
position = @menu_items.index {|i| i.name == after}
|
|
135 |
position = @menu_items.collect{|i| i.name}.index(after)
|
|
136 | 136 |
position += 1 unless position.nil? |
137 | 137 |
elsif options.delete(:last) |
138 | 138 |
position = @menu_items.size |