Commit 0b6ad31c authored by Kamil Trzcinski's avatar Kamil Trzcinski

Add missing application_setting option

parent 486177e4
module EE
# Build EE mixin
# ApplicationSetting EE mixin
#
# This module is intended to encapsulate EE-specific model logic
# and be included in the `Build` model
module Build
extend ActiveSupport::Concern
# and be included in the `ApplicationSetting` model
module ApplicationSetting
extend ActiveSupport::Prependable
def shared_runners_minutes_limit_enabled?
runner && runner.shared? && project.shared_runners_minutes_limit_enabled?
prepended do
validates :shared_runners_minutes,
numericality: { greater_than_or_equal_to: 0 }
end
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