diff options
author | Jasper Maes <jaspermaes.jm@gmail.com> | 2018-08-16 09:18:13 +0300 |
---|---|---|
committer | Jasper Maes <jaspermaes.jm@gmail.com> | 2018-08-16 09:25:06 +0300 |
commit | 7f462b630a6c7476418e8c6301081e41b91c446c (patch) | |
tree | d0c187b605cdbbd14c0d24dc9f2cc78a32327de8 /config/initializers/active_record_verbose_query_logs.rb | |
parent | 79fdfec51fa7f42f698b898dbf9ad4925aa9fdbf (diff) |
Rails5: Enable verbose query logs
Diffstat (limited to 'config/initializers/active_record_verbose_query_logs.rb')
-rw-r--r-- | config/initializers/active_record_verbose_query_logs.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/config/initializers/active_record_verbose_query_logs.rb b/config/initializers/active_record_verbose_query_logs.rb index 44f86fec7e0..1c5fbc8e830 100644 --- a/config/initializers/active_record_verbose_query_logs.rb +++ b/config/initializers/active_record_verbose_query_logs.rb @@ -47,7 +47,9 @@ module ActiveRecord end end - unless Gitlab.rails5? + if Rails.version.start_with?("5.2") + raise "Remove this monkey patch: #{__FILE__}" + else prepend(VerboseQueryLogs) unless Rails.env.production? end end |