Commit 02f8f900 authored by Rémy Coutable's avatar Rémy Coutable

Merge branch 'rails5-active-sup-subscriber' into 'master'

Make ActiveRecordSubscriber rails 5 compatible

Closes #44702

See merge request gitlab-org/gitlab-ce!19276
parents df164bb9 c37a9ef3
---
title: Make ActiveRecordSubscriber rails 5 compatible
merge_request:
author:
type: other
......@@ -4,7 +4,7 @@ module Gitlab
attach_to :active_record
def sql(event)
unless event.payload[:name] == 'CACHE'
unless event.payload.fetch(:cached, event.payload[:name] == 'CACHE')
Transaction.current&.increment
end
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment