eff_matomo 0.2.1 → 0.2.2

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
  SHA256:
3
- metadata.gz: a7acc3a74ee56d8a406372034ee391cbcdcea3b8b45906fc3f4766be453041a0
4
- data.tar.gz: ce930d0b254878f3047e9b7467bb24420b33720f514a1a5c5f6c0cbacad7b074
3
+ metadata.gz: 6bfc083e6ab2c763fc43de34312df80afa28ecda126fa70260181413ba4dc275
4
+ data.tar.gz: 81445c6e62b6e2edd081fc72fd190003c145d87272444654026fdddddb475b5e
5
5
  SHA512:
6
- metadata.gz: 5e4be46b925b9a2df0c7a252d8cbd07084343cdbc710e256c60f1139c694e2569fbbdd0fcdf8858061eea422fa252d714c05b599eb0c38d872a38fc09aa6be77
7
- data.tar.gz: cbbe856f841c2afec25db810fed9400a9124bb77ea645026f2b3622e41a31e59e6bb20ed74607fffdbb9ca27da61842c2c5bb05d7fd2e10d03488a0a5a69d47f
6
+ metadata.gz: bbe42d9ce30ae00aba2f6c4f21556fb2dad50bb926905577ae7e862ace1e53a853e24afaac7449453e7284927a66abaf910b3e81986ad2e6af3fdab8f6eab897
7
+ data.tar.gz: 3a001f1dda9e08aa0402a05bd66d4d7e106152711ae22912396c635acc15f41b2a974f7d0db74066f0673818b8c82311a74f4f6f72c5a476f160cf47756cf366
@@ -10,8 +10,8 @@ module Matomo
10
10
 
11
11
  def initialize(params)
12
12
  @label = params["label"]
13
- @visits = params["nb_visits"]
14
- @actions = params["nb_actions"]
13
+ @visits = params["nb_visits"] || 0
14
+ @actions = params["nb_actions"] || 0
15
15
  end
16
16
 
17
17
  def actions_per_visit
@@ -40,8 +40,8 @@ module Matomo
40
40
  def initialize(path, params)
41
41
  @path = path
42
42
  @label = params["label"]
43
- @hits = params["nb_hits"]
44
- @visits = params["nb_visits"]
43
+ @hits = params["nb_hits"] || 0
44
+ @visits = params["nb_visits"] || 0
45
45
  end
46
46
 
47
47
  def label
@@ -1,3 +1,3 @@
1
1
  module Matomo
2
- VERSION = "0.2.1"
2
+ VERSION = "0.2.2"
3
3
  end
@@ -12,7 +12,7 @@ module Matomo
12
12
  def matomo_tracking_embed
13
13
  content_tag(:div, id: "anon-stats") do
14
14
  content_tag(:noscript) do
15
- content_tag(:img, src: matomo_tracking_url, style: "border:0", alt: "")
15
+ tag(:img, src: matomo_tracking_url, style: "border:0", alt: "")
16
16
  end +
17
17
  javascript_tag do
18
18
  "document.getElementById('anon-stats').innerHTML = '<img src=\"#{matomo_tracking_url}\"?urlref=' + encodeURIComponent(document.referrer) + 'style=\"border:0\" alt=\"\" />';".html_safe
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: eff_matomo
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - vivian
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-10-24 00:00:00.000000000 Z
11
+ date: 2018-10-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport