librariesio-url-parser 1.0.4 → 1.0.5

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: 26ec3df36120630b6729b1d5a9b7d854acfeadede419ab34e895d0e00619fb7c
4
- data.tar.gz: 7bf32628de41c3a243b08ee3b8aa8489e5dfbfef5fe673e7f68390a6f942dbd0
3
+ metadata.gz: b7678a02447f9ecb298aca33105ed4a0a686258b39e1dbbf6069cadcc8bb5ee9
4
+ data.tar.gz: f5c7d4fa5dca4858e46f7740b33f4e54f67230e2801a2e2cfb00bfae7f1aad6a
5
5
  SHA512:
6
- metadata.gz: bbe57df347aafc5b82046f13a5e20d7c6deaf66cb67590540d122701d79bd516bb0b015b0b41f72d144e7c963f45e1ef7f67da61328aa819b8712c58d029b9af
7
- data.tar.gz: c942042bb95db767107b91aa136c61cdd8408c11cfef763038abab07e0bdc515ee032cf8979e27040988aca8ce0b879214fae367511b1cf36a48a0f5e4415071
6
+ metadata.gz: 940d8eccc878fe614347f7e18f381825f531cf2f14a0f22834bbd342e8ebf6be13e4daeb5c07e2627446ba5d5df76af8b634285731479ce6fe4d38807fb29326
7
+ data.tar.gz: 928daf9d94eeed789e059e099dd6346e7c6d1b4cbaee1f788d8d36dc2420fdd232c74a7ed68f051aa91efa26d1d6636107d89deee06e082d0fd7c2f6398b90ca
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- librariesio-url-parser (1.0.4)
4
+ librariesio-url-parser (1.0.5)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -13,5 +13,5 @@ require_relative "android_googlesource_url_parser"
13
13
  require_relative "sourceforge_url_parser"
14
14
 
15
15
  module LibrariesioURLParser
16
- VERSION = "1.0.4"
16
+ VERSION = "1.0.5"
17
17
  end
data/lib/url_parser.rb CHANGED
@@ -65,7 +65,12 @@ class URLParser
65
65
  remove_auth_user
66
66
  remove_equals_sign
67
67
  remove_scheme
68
- return nil unless includes_domain?
68
+
69
+ unless includes_domain?
70
+ self.url = nil
71
+ return nil
72
+ end
73
+
69
74
  remove_subdomain
70
75
  remove_domain
71
76
  remove_git_extension
@@ -74,6 +79,7 @@ class URLParser
74
79
  end
75
80
 
76
81
  def format_url
82
+ return nil if url.nil?
77
83
  return nil unless url.length == 2
78
84
 
79
85
  url.join('/')
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: librariesio-url-parser
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.4
4
+ version: 1.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matt Pace
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-08-17 00:00:00.000000000 Z
11
+ date: 2022-08-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake