Sha256: e6a672f3032e92c9efc248f6678a5baec05597221baf2382bbf42efe1f0c91b6
Contents?: true
Size: 533 Bytes
Versions: 9
Compression:
Stored size: 533 Bytes
Contents
require 'active_support/core_ext/hash/keys' module Telegram module Bot module Initializers # Accepts different options to initialize bot. def wrap(input, **options) case input when Symbol then by_id(input) or raise "#{name} #{input.inspect} not configured" when self then input when Hash then new(**input.symbolize_keys, **options) else new(input, **options) end end def by_id(_id) raise 'Not implemented' end end end end
Version data entries
9 entries across 9 versions & 1 rubygems