Fix: rinomina Engine.for in for_match (keyword riservata Ruby).
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -9,7 +9,7 @@ module Scoring
|
|||||||
end
|
end
|
||||||
|
|
||||||
def call
|
def call
|
||||||
Engine.for(@match).apply(session: @session, action: @action)
|
Engine.for_match(@match).apply(session: @session, action: @action)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -9,18 +9,18 @@ module Scoring
|
|||||||
"timer" => Engines::TimerEngine
|
"timer" => Engines::TimerEngine
|
||||||
}.freeze
|
}.freeze
|
||||||
|
|
||||||
def self.for(match)
|
def self.for_match(match)
|
||||||
board = match.effective_board_type
|
board = match.effective_board_type
|
||||||
klass = ENGINES.fetch(board) { Engines::GenericEngine }
|
klass = ENGINES.fetch(board) { Engines::GenericEngine }
|
||||||
klass.new(match: match)
|
klass.new(match: match)
|
||||||
end
|
end
|
||||||
|
|
||||||
def self.for_session(session)
|
def self.for_session(session)
|
||||||
for(session.match)
|
for_match(session.match)
|
||||||
end
|
end
|
||||||
|
|
||||||
def self.ensure_score_for(session)
|
def self.ensure_score_for(session)
|
||||||
for(session.match).ensure_score(session)
|
for_match(session.match).ensure_score(session)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ module Scoring
|
|||||||
end
|
end
|
||||||
|
|
||||||
def call
|
def call
|
||||||
Engine.for(@session.match).sync(session: @session, payload: @payload)
|
Engine.for_match(@session.match).sync(session: @session, payload: @payload)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user