Sha256: 2abdb838f75f62e39538f45d8434cbd7043b37d3f4bfd458d2738e2cd4461330
Contents?: true
Size: 386 Bytes
Versions: 2
Compression:
Stored size: 386 Bytes
Contents
# frozen_string_literal: true module TeBot class Cable attr_reader :message, :params def initialize(wire, message, params = {}) @wire = wire @message = message @params = params end def chat_id @message.data&.chat_id end def reply(**payload) return if chat_id.nil? @wire.send_message chat_id, **payload end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
te_bot-0.3.0 | lib/te_bot/cable.rb |
te_bot-0.2.0 | lib/te_bot/cable.rb |