blob: 3266b9f833623272190d5ae8814325be2becf0ab (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
|
# frozen_string_literal: true
# Patch to annotate sql only when the feature is enabled.
module Gitlab
module Marginalia
module ActiveRecordInstrumentation
def annotate_sql(sql)
Gitlab::Marginalia.cached_feature_enabled? ? super(sql) : sql
end
end
end
end
|