slacks 0.4.3 → 0.4.4

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: 47d70d2fd8637b680b0996c328a8bc4e904370a5
4
- data.tar.gz: 01e16f46e8f99eef67164cc69b7c80fd5d6be1e5
3
+ metadata.gz: f5dca8b35462a36816d2ac22a58904c7801e779d
4
+ data.tar.gz: ea16047ea5dbafc775bbb6d79bdd30c85446aec8
5
5
  SHA512:
6
- metadata.gz: b9ee9d64bafcade4b4d692e8364462c2217f5c4847761a565bb491ca8fbc3f05e65205969f10230fba9bc820e25f98cabffd4d1122d3eef30103902065cdaecc
7
- data.tar.gz: c73f2491c1af828ce7fa2071f620de5abda68528fe9d40949ae134bb8ee4ea6f79b44be55307b70690f9198d3e28774aea6e5ada296135f170b8daacafa9390f
6
+ metadata.gz: 423b632d2810deaac520ea364122ff15030876e66dacdde761d957bd7bd8cabd8caaa6d7d0a1a33293bec184f16e8fe051be35eb94291c595cc28f78857e1a54
7
+ data.tar.gz: 889dc9cbc90679e968006aebeac2c798981aa0dde9873e3c14bb4e21da3ab19a3756d2da0a27ee085f298c725f5db16c5bd8f53350a987c9ddad5f58c0fa0fa1
@@ -41,8 +41,7 @@ module Slacks
41
41
  as_user: true, # post as the authenticated user (rather than as slackbot)
42
42
  link_names: 1} # find and link channel names and user names
43
43
  params.merge!(attachments: MultiJson.dump(attachments)) if attachments.any?
44
- params.merge!(options.select { |key, _| [:username, :as_user, :parse, :link_names,
45
- :unfurl_links, :unfurl_media, :icon_url, :icon_emoji].member?(key) })
44
+ params.merge!(options.select { |key, _| SEND_MESSAGE_PARAMS.member?(key) })
46
45
  api("chat.postMessage", params)
47
46
  rescue Slacks::ResponseError
48
47
  $!.response
@@ -347,5 +346,20 @@ module Slacks
347
346
  end
348
347
  end
349
348
 
349
+
350
+
351
+ SEND_MESSAGE_PARAMS = %i{
352
+ username
353
+ as_user
354
+ parse
355
+ link_names
356
+ unfurl_links
357
+ unfurl_media
358
+ icon_url
359
+ icon_emoji
360
+ thread_ts
361
+ reply_broadcast
362
+ }.freeze
363
+
350
364
  end
351
365
  end
@@ -1,3 +1,3 @@
1
1
  module Slacks
2
- VERSION = "0.4.3"
2
+ VERSION = "0.4.4"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: slacks
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.3
4
+ version: 0.4.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Bob Lail
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-10-14 00:00:00.000000000 Z
11
+ date: 2017-01-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: websocket-driver