test_track_rails_client 4.0.0.alpha13 → 4.0.0.alpha14

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: f4a778c1664c68c4ddab8f3ca75a3a3b55c10650
4
- data.tar.gz: 6fcf9637535419b34e4ce377a91804c0497623fe
3
+ metadata.gz: 78829ab3aa1352782eb7777f07ac0c66c2b4a21a
4
+ data.tar.gz: 807fb0fd4539fa956a0047c2e878863e0221a664
5
5
  SHA512:
6
- metadata.gz: b35d4919150c7fd05b48d92b63779def2829e5d113c35fa2d53b5a66011931e691d3da037e74cf410133cffaf04bdc630b4d61bf6ab30f8ea94232a2786ab922
7
- data.tar.gz: e853d6515ab4417ce3044135e96f4a206a0e19dd8d44b49ce3e7a24a210206d4af3768916a4b2ab634d6bd3966851ca5b8b7ce6e06a5545d48e433eba7d9c125
6
+ metadata.gz: bca371e700670448a29d2e73436147804fcd07715694b9b8e2b45d10a2a04552eb11418d711cd166e3889aa0b22595f219cbbeee3ff463df8271d1409e87f2d4
7
+ data.tar.gz: 6265f59eb1c76d43743b937ef56ded1da37c5d5f87212efefca97558ab8ce58ebfbf9253f11719aa686770b1d7c1d34ac7b6e5748e13e8bccb3fffff2b227922
@@ -95,10 +95,8 @@ class TestTrack::Session
95
95
  end
96
96
 
97
97
  def _cookie_domain
98
- if bare_ip_address?
98
+ if bare_ip_address? || fully_qualified_cookie_domain_enabled?
99
99
  request.host
100
- elsif fully_qualified_cookie_domain_enabled?
101
- fully_qualified_domain
102
100
  else
103
101
  wildcard_domain
104
102
  end
@@ -108,16 +106,12 @@ class TestTrack::Session
108
106
  request.host.match(Resolv::AddressRegex)
109
107
  end
110
108
 
111
- def fully_qualified_domain
112
- public_suffix_host.name
113
- end
114
-
115
109
  def wildcard_domain
116
- "." + public_suffix_host.domain
110
+ "." + (public_suffix_domain || request.host)
117
111
  end
118
112
 
119
- def public_suffix_host
120
- @public_suffix_host ||= PublicSuffix.parse(request.host, default_rule: nil)
113
+ def public_suffix_domain
114
+ @public_suffix_domain ||= PublicSuffix.domain(request.host, default_rule: nil)
121
115
  end
122
116
 
123
117
  def manage_cookies!
@@ -1,3 +1,3 @@
1
1
  module TestTrackRailsClient
2
- VERSION = "4.0.0.alpha13" # rubocop:disable Style/MutableConstant
2
+ VERSION = "4.0.0.alpha14" # rubocop:disable Style/MutableConstant
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: test_track_rails_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.0.alpha13
4
+ version: 4.0.0.alpha14
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ryan O'Neill
@@ -13,7 +13,7 @@ authors:
13
13
  autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
- date: 2018-10-30 00:00:00.000000000 Z
16
+ date: 2018-11-09 00:00:00.000000000 Z
17
17
  dependencies:
18
18
  - !ruby/object:Gem::Dependency
19
19
  name: airbrake