diff options
author | Stefan Wintermeyer <stefan.wintermeyer@amooma.de> | 2013-01-18 19:06:01 +0100 |
---|---|---|
committer | Stefan Wintermeyer <stefan.wintermeyer@amooma.de> | 2013-01-18 19:06:01 +0100 |
commit | 313a6bfb2c5eddca7872bda007b7eae87306e5c6 (patch) | |
tree | a2b59b85d214b564df1259bc96302edfe014ad6c /config/initializers | |
parent | 8d1167c53e9edaf6e5a2b3e89dd4fd2a2c872dbb (diff) |
Update config/initializers/update_gs_version_number.rb
Diffstat (limited to 'config/initializers')
-rw-r--r-- | config/initializers/update_gs_version_number.rb | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/config/initializers/update_gs_version_number.rb b/config/initializers/update_gs_version_number.rb index 914f007..972c480 100644 --- a/config/initializers/update_gs_version_number.rb +++ b/config/initializers/update_gs_version_number.rb @@ -2,5 +2,7 @@ # It equals the branch in git. # if !ENV['GS_VERSION'].nil? && GsParameter.table_exists? && GsParameter.get('GEMEINSCHAFT_VERSION') != ENV['GS_VERSION'] - GsParameter.where(:name => 'GEMEINSCHAFT_VERSION').first.update_attributes(:name => ENV['GS_VERSION']) -end
\ No newline at end of file + if GsParameter.where(:name => 'GEMEINSCHAFT_VERSION').any? + GsParameter.where(:name => 'GEMEINSCHAFT_VERSION').first.update_attributes(:name => ENV['GS_VERSION']) + end +end |