Class: TeBot::Message::Query

Inherits:
Object
  • Object
show all
Defined in:
lib/te_bot/message.rb

Instance Method Summary collapse

Constructor Details

#initialize(message) ⇒ Query

Returns a new instance of Query.



125
126
127
# File 'lib/te_bot/message.rb', line 125

def initialize(message)
  @query = message.dig("query") || message.dig("data")
end

Instance Method Details

#parseObject



129
130
131
# File 'lib/te_bot/message.rb', line 129

def parse
  @query
end