followers_number 0.0.6 → 0.0.7
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: 16934587498fd73c956762141d13ff5ce8aa443a80f8eb37b5a341a1a8b47099
|
4
|
+
data.tar.gz: a144a7da9973cdee0ea135a4a1ba1850a9cbe4ec37433b26490df009ae9d9fb6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a9fb964c75d33ebc7f2ee76493d19d8dbc7bd7b895fd823d4340e4fc502ef792bbeb052a85ffac5969aa004ab3c3340d13888c26e0f714e69d1f8443cc8734d3
|
7
|
+
data.tar.gz: adb3583ea538d4a848e554e47dfa259be843cc9304b1d7b467d8baebdfa99b629c3c22a4af380bb19337d835a1dc6ed2612bc3e22682dabe4c5f61e876161803
|
data/lib/followers_number.rb
CHANGED
@@ -6,6 +6,7 @@ require_relative 'followers_number/parsers/twitter'
|
|
6
6
|
require_relative 'followers_number/parsers/instagram'
|
7
7
|
require_relative 'followers_number/parsers/youtube'
|
8
8
|
require_relative 'followers_number/parsers/facebook'
|
9
|
+
require_relative 'followers_number/parsers/medium'
|
9
10
|
|
10
11
|
require_relative 'followers_number/request'
|
11
12
|
require_relative 'followers_number/validator'
|
@@ -4,7 +4,8 @@ module FollowersNumber
|
|
4
4
|
'twitter.com' => FollowersNumber::Parsers::Twitter,
|
5
5
|
'instagram.com' => FollowersNumber::Parsers::Instagram,
|
6
6
|
'youtube.com' => FollowersNumber::Parsers::Youtube,
|
7
|
-
'facebook.com' => FollowersNumber::Parsers::Facebook
|
7
|
+
'facebook.com' => FollowersNumber::Parsers::Facebook,
|
8
|
+
'medium.com' => FollowersNumber::Parsers::Medium
|
8
9
|
}
|
9
10
|
|
10
11
|
def self.call(profile_url, response)
|
@@ -2,7 +2,7 @@ module FollowersNumber
|
|
2
2
|
class Validator
|
3
3
|
class InvalidProfileURL < StandardError; end
|
4
4
|
|
5
|
-
NETWORKS = %w[twitter.com instagram.com youtube.com facebook.com]
|
5
|
+
NETWORKS = %w[twitter.com instagram.com youtube.com facebook.com medium.com]
|
6
6
|
|
7
7
|
def self.validate!(profile_url)
|
8
8
|
unless NETWORKS.include?(URI.parse(profile_url.to_s.downcase).host)
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: followers_number
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Paweł Dąbrowski
|
@@ -68,6 +68,7 @@ files:
|
|
68
68
|
- lib/followers_number/parser.rb
|
69
69
|
- lib/followers_number/parsers/facebook.rb
|
70
70
|
- lib/followers_number/parsers/instagram.rb
|
71
|
+
- lib/followers_number/parsers/medium.rb
|
71
72
|
- lib/followers_number/parsers/twitter.rb
|
72
73
|
- lib/followers_number/parsers/youtube.rb
|
73
74
|
- lib/followers_number/request.rb
|