telegram-bot-ruby 0.3.5 → 0.3.6

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: c12e00f696103b14d70d141923f8cbe57ab6b902
4
- data.tar.gz: 83e391cc4f2a89c8a6eed5e43d8ff5e304b05ca3
3
+ metadata.gz: 6338f01513d52c67f22298610ac825a9c5f5bef0
4
+ data.tar.gz: 180c6e6bc5e491271c52014362fa9ce92ac836c8
5
5
  SHA512:
6
- metadata.gz: c2cbfb05f587b9644f58b0a5281a2f5364038b04c6f0bf195135d3e422fb1eb091fbe7e3d20ff4fff3facc02d17da477ccfc6219ac647f873f93a118b4754849
7
- data.tar.gz: b912880f81e021d5d96f908d29bd2842614991721a3b4c0ee7f2e386021bc71e7c28d426f4836a68ca1f664db2065035264457f3ab3e44adbd299ccf3e45e13a
6
+ metadata.gz: d099f0a0c926382dc11efbbc6925898d72f37396868d909d53035298332d7a3b312341758b05c7c4a63884925788cffceab2acd9cf1427e817eddcd365f3bd36
7
+ data.tar.gz: 190ba1f3de31744e7b45a543fd58aa0249f6efe5166392cf041e8096418b59be3180e0f257807a2a87ed97f2b353e7d15ca688d3dbc16b8c0eae026f2330e7d9
@@ -23,7 +23,11 @@ module Telegram
23
23
  end
24
24
 
25
25
  def listen(&block)
26
- loop { fetch_updates(&block) }
26
+ logger.info('Starting bot')
27
+ running = true
28
+ Signal.trap('INT') { running = false }
29
+ fetch_updates(&block) while running
30
+ exit
27
31
  end
28
32
 
29
33
  def fetch_updates
@@ -1,5 +1,5 @@
1
1
  module Telegram
2
2
  module Bot
3
- VERSION = '0.3.5'
3
+ VERSION = '0.3.6'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: telegram-bot-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.5
4
+ version: 0.3.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alexander Tipugin
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2015-09-12 00:00:00.000000000 Z
11
+ date: 2015-09-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: httmultiparty