aboutsummaryrefslogtreecommitdiffstats
path: root/activejob/lib/active_job/queue_priority.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activejob/lib/active_job/queue_priority.rb')
-rw-r--r--activejob/lib/active_job/queue_priority.rb6
1 files changed, 2 insertions, 4 deletions
diff --git a/activejob/lib/active_job/queue_priority.rb b/activejob/lib/active_job/queue_priority.rb
index b02202fcc8..399d7a135a 100644
--- a/activejob/lib/active_job/queue_priority.rb
+++ b/activejob/lib/active_job/queue_priority.rb
@@ -4,7 +4,7 @@ module ActiveJob
# Includes the ability to override the default queue priority.
module ClassMethods
- mattr_accessor(:default_priority)
+ mattr_accessor :default_priority
# Specifies the priority of the queue to create the job with.
#
@@ -27,9 +27,7 @@ module ActiveJob
end
included do
- class_attribute :priority, instance_accessor: false
-
- self.priority = default_priority
+ class_attribute :priority, instance_accessor: false, default: default_priority
end
# Returns the priority that the job will be created with