mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
DEV: Apply syntax_tree formatting to lib/*
This commit is contained in:
@@ -17,16 +17,16 @@ module ScreeningModel
|
||||
end
|
||||
end
|
||||
|
||||
included do
|
||||
before_validation :set_default_action
|
||||
end
|
||||
included { before_validation :set_default_action }
|
||||
|
||||
def set_default_action
|
||||
self.action_type ||= self.class.actions[self.class.df_action]
|
||||
end
|
||||
|
||||
def action_name=(arg)
|
||||
raise ArgumentError.new("Invalid action type #{arg}") if arg.nil? || !self.class.actions.has_key?(arg.to_sym)
|
||||
if arg.nil? || !self.class.actions.has_key?(arg.to_sym)
|
||||
raise ArgumentError.new("Invalid action type #{arg}")
|
||||
end
|
||||
self.action_type = self.class.actions[arg.to_sym]
|
||||
end
|
||||
|
||||
|
Reference in New Issue
Block a user