-
-
Save johnkpaul/abf55b98e5e5436a3c37b61c9a747897 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Statesman | |
module Machine | |
class << self | |
alias_method :state_original, :state | |
end | |
def self.state name, args | |
binding.pry | |
state_original(name, args) | |
end | |
end | |
end | |
class ItemStateMachine | |
include Statesman::Machine | |
state :new, initial: true | |
state :pending_tech_review | |
state :nw_can_repair | |
end | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment