framed_rails 0.1.4 → 0.1.5

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.
data/lib/framed/rails.rb CHANGED
@@ -15,17 +15,18 @@ ActionController::Base.class_eval do
15
15
  end
16
16
 
17
17
  def framed_report_request
18
+ return unless framed_included?(request)
19
+
18
20
  begin
19
21
  anonymous_id = cookies.signed[Framed.anonymous_cookie]
20
22
  user_id = send(Framed.user_id_controller_method)
21
23
 
22
- if user_id.nil? && anonymous_id.nil?
24
+ if anonymous_id.nil?
23
25
  anonymous_id = Framed.new_anonymous_id
24
- cookies.signed.permanent[Framed.anonymous_cookie] = {:value => anonymous_id, :httponly => true}
26
+ cookie = {:value => anonymous_id, :httponly => true}
27
+ cookies.signed.permanent[Framed.anonymous_cookie] = cookie
25
28
  end
26
29
 
27
- return unless framed_included?(request)
28
-
29
30
  cleaned_params = params.except(:controller, :action).to_h
30
31
  event = {
31
32
  :type => :track,
@@ -1,4 +1,4 @@
1
1
  # encoding: utf-8
2
2
  module Framed
3
- VERSION = "0.1.4"
3
+ VERSION = "0.1.5"
4
4
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: framed_rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.4
4
+ version: 0.1.5
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2015-08-26 00:00:00.000000000 Z
12
+ date: 2015-08-28 00:00:00.000000000 Z
13
13
  dependencies: []
14
14
  description: ! 'TK
15
15