any_number

It going to be executed if the incoming message contains at least one number (integer or float) and it will return as a parameter an array with the numbers found.

any_number(&block)

Platforms

Platform
Supported

Messenger

WhatsApp

Telegram

Usage

class MainContext < Conversation

  def blocks

    any_number do |numbers|
      @reply.text "You've sent these numers: #{numbers.join(" ,")}"
    end

  end
  
end

Last updated