diff options
author | Dmitriy Zaporozhets <dzaporozhets@sphereconsultinginc.com> | 2012-02-20 10:38:03 +0200 |
---|---|---|
committer | Dmitriy Zaporozhets <dzaporozhets@sphereconsultinginc.com> | 2012-02-20 10:38:03 +0200 |
commit | 40ac2ebc2129905cc0831f824dc1c6dc824efc90 (patch) | |
tree | 8b9f14fa6ce496a5310f7d0af6da4544af275a00 | |
parent | 313d96e42b313a0af5ab50fa233bf43e27118b3f (diff) | |
download | gitlab-ce-40ac2ebc2129905cc0831f824dc1c6dc824efc90.tar.gz |
fixed bug with branch/commit detection in select
-rw-r--r-- | app/helpers/application_helper.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 0d435059fcb..aec3dd5145a 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -54,7 +54,7 @@ module ApplicationHelper # If reference is commit id - # we should add it to branch/tag selectbox - if(@ref && !options.include?(@ref) && + if(@ref && !options.flatten.include?(@ref) && @ref =~ /^[0-9a-zA-Z]{6,52}$/) options << ["Commit", [@ref]] end |