Fix Rails/RakeEnvironment
cop (#28782)
This commit is contained in:
parent
30b193b856
commit
127503eb2c
3 changed files with 11 additions and 13 deletions
|
@ -15,7 +15,7 @@ namespace :db do
|
|||
end
|
||||
end
|
||||
|
||||
task :pre_migration_check do
|
||||
task pre_migration_check: :environment do
|
||||
version = ActiveRecord::Base.connection.select_one("SELECT current_setting('server_version_num') AS v")['v'].to_i
|
||||
abort 'This version of Mastodon requires PostgreSQL 9.5 or newer. Please update PostgreSQL before updating Mastodon' if version < 90_500
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue