diff options
Diffstat (limited to 'lib/gitlab/query_limiting/active_support_subscriber.rb')
-rw-r--r-- | lib/gitlab/query_limiting/active_support_subscriber.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/gitlab/query_limiting/active_support_subscriber.rb b/lib/gitlab/query_limiting/active_support_subscriber.rb index 138fae7b641..4bfd526914b 100644 --- a/lib/gitlab/query_limiting/active_support_subscriber.rb +++ b/lib/gitlab/query_limiting/active_support_subscriber.rb @@ -6,10 +6,10 @@ module Gitlab attach_to :active_record def sql(event) - return if !Transaction.current || event.payload.fetch(:cached, event.payload[:name] == 'CACHE') + return if !::Gitlab::QueryLimiting::Transaction.current || event.payload.fetch(:cached, event.payload[:name] == 'CACHE') - Transaction.current.increment - Transaction.current.executed_sql(event.payload[:sql]) + ::Gitlab::QueryLimiting::Transaction.current.increment + ::Gitlab::QueryLimiting::Transaction.current.executed_sql(event.payload[:sql]) end end end |