linkhum-url 0.1.7 → 0.1.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/lib/linkhum/url.rb +5 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cec615cf257a77a0b7ed71f4e74f1b4002f3d697
|
4
|
+
data.tar.gz: 27d62d7d172ad1d1cb52e85374354d2e72c403d8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0c09b139f99966d937e43b0cd27537461b8c421dc15587be5c015c53a86d6ad59c71d08862683cdf32304ad6b981a585e18f62aac5c825416ce6324636b2dab8
|
7
|
+
data.tar.gz: a5024c7a8633382e45b01443e383c3f400d64e976c56321636b617627463037c1323829fa21a307e0aa52ce5d19da0814833f540bfefdde7e9fc4873d6699882
|
data/CHANGELOG.md
CHANGED
data/lib/linkhum/url.rb
CHANGED
@@ -30,6 +30,11 @@ module Linkhum
|
|
30
30
|
end
|
31
31
|
au_path.force_encoding(Encoding::ASCII_8BIT)
|
32
32
|
url_encoded[:path] = encode_component(au_path)
|
33
|
+
decoded_path = human_readable[:path].dup
|
34
|
+
if !decoded_path.force_encoding(Encoding::UTF_8).valid_encoding?
|
35
|
+
human_readable[:path] = au.path
|
36
|
+
end
|
37
|
+
|
33
38
|
human_readable[:query] = unencode_component(au.query, false)
|
34
39
|
if au.query
|
35
40
|
decoded_query = human_readable[:query].dup
|
@@ -37,7 +42,6 @@ module Linkhum
|
|
37
42
|
human_readable[:query] = au.query
|
38
43
|
end
|
39
44
|
end
|
40
|
-
|
41
45
|
if au.query
|
42
46
|
# see above
|
43
47
|
au_query = au.query.dup
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: linkhum-url
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alexey Makhotkin
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-08-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: addressable
|
@@ -112,7 +112,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
112
112
|
version: '0'
|
113
113
|
requirements: []
|
114
114
|
rubyforge_project:
|
115
|
-
rubygems_version: 2.6.
|
115
|
+
rubygems_version: 2.6.14
|
116
116
|
signing_key:
|
117
117
|
specification_version: 4
|
118
118
|
summary: Linkhum-URL creates both URL-encoded and readable versions of URLs
|