Skip to content

Instantly share code, notes, and snippets.

@cagmz

cagmz/call.rb Secret

Last active September 7, 2019 00:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cagmz/faa1e48d585c4ac7f39f2cc8bc5f5718 to your computer and use it in GitHub Desktop.
Save cagmz/faa1e48d585c4ac7f39f2cc8bc5f5718 to your computer and use it in GitHub Desktop.
class Caller
class << self
def call(id:)
puts id
end
end
end
######
class Caller
def self.call(id:)
new(id: id).call
end
def initialize(id:)
@id = id
end
def call
puts id
end
attr_reader :id
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment