lightweight_user_agent_parser 1.4.0 → 1.5.0

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: bcb44b3bbeb4da6e7c0de51a266c92de697775b1
4
- data.tar.gz: 794051f4544389286b69c7c3a3f6c3c61e9f4d3c
3
+ metadata.gz: 9504f42e004a58d9991a9c6e6c1df54453f613db
4
+ data.tar.gz: dec473cd678e3cb90c8c987abf8fc8cc33c4a55b
5
5
  SHA512:
6
- metadata.gz: 93b2df1cbb426b23c16f9e673c8cb15a1b1218bc036d691027ff4daf0273b4abcfeedb40f3a50eacfb32f5b4ad372a00726fb9d72a956d4e672ac01e85c9e847
7
- data.tar.gz: f70ab3a2f275fa8f30bfb8449c9c5554c4f58e58bd1f66429f304c72bdf16e7fd8f1e766b2fcafb25ca7c3c283d6baac8991134201eb509629646a0d4d11abfd
6
+ metadata.gz: 99cabb4562ef0c805eccc68e2f0763026ed7cbcbd2c6e5713ac8ac8ab616ea340247a663f3f639070e073fdce9e413b65c107105d2bae2840f2b7f02019ef66a
7
+ data.tar.gz: 8ec4f220ee52980893fd7558fdf22f0f96764442c1974d51216f07ec907ca4e8a0b506990eb85f6b953a4c8aa8cd0cfe496abe05c07553f0c599cc67e7109796
@@ -51,6 +51,7 @@ class LightweightUserAgentParser
51
51
  MOBILE_REGEXP = /#{mobile_regexp_str}/i.freeze
52
52
 
53
53
  desktop_device_matcher = DEVICES_META.select { |ary| DESKTOP_DEVICES.include?(ary[0]) }.map { |e| e[1] }.join('|')
54
+ desktop_device_matcher << '|Mozilla/\d\.\d.*(compatible.*)'
54
55
  DESKTOP_REGEXP = /#{desktop_device_matcher}/i.freeze
55
56
 
56
57
  ANONYMIZED_REGEXP = Regexp.new(DEVICES_META.find { |sym, regex_str| sym == :anonymized }.last, Regexp::IGNORECASE)
@@ -1,3 +1,3 @@
1
1
  class LightweightUserAgentParser
2
- VERSION = '1.4.0'.freeze
2
+ VERSION = '1.5.0'.freeze
3
3
  end
@@ -78,6 +78,11 @@ RSpec.describe LightweightUserAgentParser do
78
78
  ua_str: 'Firefox/33.1 (x86 de); anonymized by Abelssoft 2048434593',
79
79
  mobile: false,
80
80
  platform: 'anonymized'
81
+ },
82
+ {
83
+ ua_str: 'Mozilla/4.0 (compatible;)',
84
+ mobile: false,
85
+ platform: 'other'
81
86
  }
82
87
  ]
83
88
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lightweight_user_agent_parser
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.0
4
+ version: 1.5.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Emarsys Technologies
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2016-02-03 00:00:00.000000000 Z
13
+ date: 2016-02-12 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: bundler