Check current attributes' docs. it will help you https://api.rubyonrails.org/v8.0.0/classes/ActiveSupport/CurrentAttributes.html