botomizer 0.1.12 → 0.1.13

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a6318e5c6ebdc4bd1c25f6bc1f355c8dfea72368
4
- data.tar.gz: 0bb2606f2619f9f359c352d4d8ba09dd34af9aef
3
+ metadata.gz: f316f2b2731f7ae5de679a44741fcef47c18198b
4
+ data.tar.gz: 86048d21e5f29b21fa3b8e103656317d43ab6fbc
5
5
  SHA512:
6
- metadata.gz: 40032c28c9b28cc4cc361c6ed2d7a32899b649598377806172c9461576de31edccef6e0024672ef93187b28c9f62bd03069dfa80b23b9a192a477f01716993cf
7
- data.tar.gz: e6dbb1b7307a5c65f61aba21b20669d6aab981661cba869dfe5a8beb88640c2fde409937bd837f69331787b80640f132afdeeb125ff4c9092f00a22a6630b5d0
6
+ metadata.gz: 1327aed0030e918f435a6956be811726a9d1691d74a3a4259a3929db68d0e48245dba0eec3d8c601a7e19af8f52698627d630531fc90d0f457f27907f301a3b3
7
+ data.tar.gz: d990f70fedc3f67a851c0563dd2b7e1199a4cac57151581e214d6cdae0c23e0255bafcd730f9083230e2153dab88b4ee34e783ad7eb9f93ff7160b13916e3c05
@@ -78,4 +78,14 @@ class Botomizer::Client
78
78
  raise Botomizer::ResponseError.new(result[:message]) if result[:status] == :failed
79
79
  result
80
80
  end
81
+
82
+ def delete_message
83
+ bot.delete_message
84
+ end
85
+
86
+ def delete_message!
87
+ result = delete_message
88
+ raise Botomizer::ResponseError.new(result[:message]) if result[:status] == :failed
89
+ result
90
+ end
81
91
  end
@@ -53,6 +53,10 @@ module Botomizer::Telegram
53
53
  def send_message(text, options = {})
54
54
  send(:sendMessage, {chat_id: @chat.id, text: text, parse_mode: 'HTML'}.merge(options))
55
55
  end
56
+
57
+ def delete_message
58
+ send(:deleteMessage, {chat_id: @chat.id, message_id: @message.id})
59
+ end
56
60
  end
57
61
  end
58
62
 
@@ -1,3 +1,3 @@
1
1
  module Botomizer
2
- VERSION = '0.1.12'
2
+ VERSION = '0.1.13'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: botomizer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.12
4
+ version: 0.1.13
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alex Belenky