pechkin 0.1.2 → 0.1.3

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
  SHA256:
3
- metadata.gz: bb1a7e85a4a99db8e70543bfc0044f285f2a1cb9aaca2b3370d8d1eb1f9a0f26
4
- data.tar.gz: 94b8651f8f10892ebb8578fd1a0ca8e47a9e358ce3bc1590dd46851bb8b5fe09
3
+ metadata.gz: 3e695894f50c29133f8399871c1dc8f1c8bdb9a489771ffe79c8bff0e8dc2afa
4
+ data.tar.gz: bf863d530c1169f1416e8d267fc7a81543e5b4d70d254c3fe969c366f914f601
5
5
  SHA512:
6
- metadata.gz: fa4bbc15a5a59c320152fd2fee602e6e6a49642ab315a569c27fc1f7654b55e99e6db749dd2a819c45dfcced81e644be85b2b7916461330e32aece8255e7cbdb
7
- data.tar.gz: 9da51f818a0a76eade9c1c87608616a227833b1f1979352425ac97ec0b9ca2867ec7bb7dcde73435b43c09eac5bcb5654ae2fa627c2090fe2c11b054c5bae226
6
+ metadata.gz: bf403faa6d076ff2773e4dbfcedd80e364a396c873d5b23f2835883267e582e0d57306f93aee5556c1c7134f863101f61552b90efab632e5d75ea637aa630385
7
+ data.tar.gz: 1960f894872b5112156aa893b9a38869f7ccc455ebe9104cf1f3bfe371c97035e54667dde86c7cb4d238802248d763f5550f0cd6a1ae6b510076748100493848
@@ -50,6 +50,8 @@ module Pechkin
50
50
  def send_message(chat, message, options)
51
51
  text = CGI.unescape_html(message)
52
52
 
53
+ return [chat, 'not sent: empty', ''] if text.strip.empty?
54
+
53
55
  params = options.update(channel: chat, text: text)
54
56
  url = 'https://slack.com/api/chat.postMessage'
55
57
  response = post_data(url, params, headers: @headers)
@@ -1,7 +1,7 @@
1
1
  module Pechkin
2
2
  # Keeps actual version
3
3
  module Version
4
- VERSION = [0, 1, 2].freeze
4
+ VERSION = [0, 1, 3].freeze
5
5
  class << self
6
6
  def version_string
7
7
  VERSION.join('.')
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pechkin
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ilya Arkhanhelsky
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-11-14 00:00:00.000000000 Z
11
+ date: 2019-11-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: grape