postrank-uri 1.0.20 → 1.0.21

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: 2a453df060f3bb0d7ea04c7031d17f9e2039e8fc
4
- data.tar.gz: fc665791c45e60179c706e9e0e2b3c8c50a58f73
3
+ metadata.gz: 25f156e4f2a2df514cf537a05b359d510fedc5d7
4
+ data.tar.gz: 2616681c902aa2b371c8d5e3a256ea15111ae0f8
5
5
  SHA512:
6
- metadata.gz: 4c6eec4d6e64e4c400d1ba9e2508a6bca95008452d3e64f22511b56236892a12afd582a7d8be28b5044e0e03f709459f5bba238359ac6408d42221912e8970a3
7
- data.tar.gz: 7816c251f9ba449f2f3ea3c8e8e4fb1f80c2e76f8fd004c2c73021b3e47fc7cc1068467f90e17986f041ea948c375b24ce7248a837d8f0d13dedc1f0c4773ed1
6
+ metadata.gz: 47204dad9f8c06a70f477bf1dffcc27b50e2668702f400239034579d1190b5492ad5295823893753d6d28d57843f9786c3265125a1764aba8c3b9f1f55581832
7
+ data.tar.gz: 6b6a5dd1c1360cdbb1ba32a3a5e34f087b74f5999264b94339c0f26cebfa614471de6c5ca9774532da5b88b12f32996c65068396cac5189f3f8509ddad9447ac
@@ -0,0 +1,15 @@
1
+ language: ruby
2
+ cache: bundler
3
+ rvm:
4
+ - 2.1
5
+ - 2.2
6
+ - 2.3
7
+ - 2.4.0
8
+ before_install:
9
+ - gem install bundler
10
+ install:
11
+ - bundle install --jobs=3 --retry=3
12
+ - bundle exec appraisal install
13
+ script:
14
+ - bundle exec rake
15
+ - bundle exec rake appraisal
data/README.md CHANGED
@@ -1,5 +1,7 @@
1
1
  # PostRank URI
2
2
 
3
+ [![Gem Version](https://badge.fury.io/rb/postrank-uri.svg)](https://rubygems.org/gems/postrank-uri) [![Build Status](https://travis-ci.org/postrank-labs/postrank-uri.svg?branch=master)](https://travis-ci.org/postrank-labs/postrank-uri)
4
+
3
5
  A collection of convenience methods (Ruby 1.8 & Ruby 1.9) for dealing with extracting, (un)escaping, normalization, and canonicalization of URIs. At PostRank we process over 20M URI associated activities each day, and we need to make sure that we can reliably extract the URIs from a variety of text formats, deal with all the numerous and creative ways users like to escape and unescape their URIs, normalize the resulting URIs, and finally apply a set of custom canonicalization rules to make sure that we can cross-reference when the users are talking about the same URL.
4
6
 
5
7
  In a nutshell, we need to make sure that creative cases like the ones below all resolve to same URI:
@@ -133,7 +133,7 @@ module PostRank
133
133
  u = parse(uri)
134
134
  u.query = u.query.tr('+', ' ') if u.query
135
135
  u.to_s.gsub(URIREGEX[:unescape]) do |encoded|
136
- if encoded.match? URIREGEX[:reserved_characters]
136
+ if !encoded.match(URIREGEX[:reserved_characters]).nil?
137
137
  encoded
138
138
  else
139
139
  [encoded.delete('%')].pack('H*')
@@ -1,5 +1,5 @@
1
1
  module PostRank
2
2
  module URI
3
- VERSION = "1.0.20"
3
+ VERSION = "1.0.21"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: postrank-uri
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.20
4
+ version: 1.0.21
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ilya Grigorik
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-03-05 00:00:00.000000000 Z
11
+ date: 2017-03-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: addressable
@@ -127,6 +127,7 @@ extra_rdoc_files: []
127
127
  files:
128
128
  - ".gitignore"
129
129
  - ".rspec"
130
+ - ".travis.yml"
130
131
  - Appraisals
131
132
  - Gemfile
132
133
  - LICENSE