slack_twitter_egosa 1.0.2 → 1.0.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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a1d6bc6e15e4e5d0d0c7f58eb941f0d811f69c2025382ca91e41db5091b80ab5
|
4
|
+
data.tar.gz: 4c8ee7c3ada2ce6882448b8488dd71055ee6902f488b244babf6b063529ac456
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 30b2a68998e935b64d530b5c6f6ef845aaa21b32660773fb8c35ddd822f6c54e1de872614459e9979f41fec639fa379e22d394a751a638836c5e1903f8481b43
|
7
|
+
data.tar.gz: f8f416bf8a1e6ffa4f827cdc8e2ed628682f04cdcb2f4d2f06aa5147ffef3fda060abcd48123974aa7cafadccb30df085b8baee3dfe746e0f5b2cf497835aa43
|
data/lib/slack_twitter_egosa.rb
CHANGED
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
require 'slack_twitter_egosa/version'
|
2
4
|
require 'slack_twitter_egosa/slack_poster'
|
3
5
|
require 'slack_twitter_egosa/word_manager'
|
@@ -66,11 +68,6 @@ module SlackTwitterEgosa
|
|
66
68
|
end
|
67
69
|
|
68
70
|
def match_on_home_timeline?(status)
|
69
|
-
if status.retweet?
|
70
|
-
status = status.retweeted_status
|
71
|
-
return false if status.user.following?
|
72
|
-
end
|
73
|
-
|
74
71
|
mute_users.unmatch?(status.user.screen_name) && home_timeline_words.match?(CGI.unescapeHTML(status.attrs[:full_text]))
|
75
72
|
end
|
76
73
|
|
@@ -94,6 +91,11 @@ module SlackTwitterEgosa
|
|
94
91
|
next unless before_home_timeline_since_id
|
95
92
|
|
96
93
|
statuses.reverse_each do |status|
|
94
|
+
if status.retweet?
|
95
|
+
status = status.retweeted_status
|
96
|
+
next if status.user.following?
|
97
|
+
end
|
98
|
+
|
97
99
|
poster.post_status(status) if match_on_home_timeline?(status)
|
98
100
|
end
|
99
101
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: slack_twitter_egosa
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- abcang
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-05-
|
11
|
+
date: 2018-05-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: dotenv
|