impressionist 1.4.5 → 1.4.6

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: 81262fb9bc635b7807f03083d9f0a397f8f1d63f
4
- data.tar.gz: f9db8dc841a204fed13f6394ac11f03de8b6534b
3
+ metadata.gz: e54acf13c5302ba85596ef90c1a3a5c62b00600e
4
+ data.tar.gz: abd480468c4233dc53d90a9c99e33e9c4d8f92df
5
5
  SHA512:
6
- metadata.gz: e06ea3557bac54ffafb0e067193ede993654a37a6be75cf012c05b8145fd3d73448df69517e860e8d89a50581421699ef0e3536c868556551175280c4ae4c4f3
7
- data.tar.gz: b3dc48b55a06c462e11df5d293594fb48d5607779f98be349970b78f969a21efdbfb0577d1a09ae904cac2d79e9ecaab0abc4da6a2fb7b9c6f169f0896b6291b
6
+ metadata.gz: c12ab157990533c5fed66d2db6e7c8ba614d778bc66751c5bf9eaa142464c1d91664571fe8767b0ad29e59f813e68f804c3447a5a09ad8bf26cb8988debef9dd
7
+ data.tar.gz: 08bfbbe4c048647c2ff2246bf7d0bec789643d26da13344fdb7ac8d0fca11cedc010bd95e6cb82b3e4a7275747bfdab24313045dfba8f955c143b3afffbe528b
@@ -1,3 +1,13 @@
1
+ == 1.4.5 (2013-07-17)
2
+ * Fixed update_counters raising an exception #97
3
+
4
+ == 1.4.4 (2013-07-15)
5
+ * Updated templates/impression.rb
6
+
7
+ == 1.4.3 (2013-07-15)
8
+ * Fixed Generators #96
9
+ * Remove pending tests, added tags
10
+
1
11
  == 1.4.2 (2013-07-12)
2
12
  * Added Mongoid Support
3
13
  * Support Rails > 3.1 < 4.0
@@ -29,7 +29,11 @@ module Impressionist
29
29
  def impressionist_count(options={})
30
30
  options.reverse_merge!(:filter=>:request_hash, :start_date=>nil, :end_date=>Time.now)
31
31
  imps = options[:start_date].blank? ? impressions : impressions.where("created_at>=? and created_at<=?",options[:start_date],options[:end_date])
32
- options[:filter] == :all ? imps.count : imps.count(options[:filter], :distinct => true)
32
+ if Rails::VERSION::MAJOR == 4
33
+ options[:filter] == :all ? imps.count : imps.select(options[:filter]).distinct.count
34
+ else
35
+ options[:filter] == :all ? imps.count : imps.count(options[:filter], :distinct => true)
36
+ end
33
37
  end
34
38
 
35
39
  def update_impressionist_counter_cache
@@ -1,3 +1,3 @@
1
1
  module Impressionist
2
- VERSION = "1.4.5"
2
+ VERSION = "1.4.6"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: impressionist
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.5
4
+ version: 1.4.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - johnmcaliley
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-07-19 00:00:00.000000000 Z
11
+ date: 2013-08-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: httpclient
@@ -339,7 +339,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
339
339
  version: 1.3.6
340
340
  requirements: []
341
341
  rubyforge_project:
342
- rubygems_version: 2.0.2
342
+ rubygems_version: 2.0.5
343
343
  signing_key:
344
344
  specification_version: 4
345
345
  summary: Easy way to log impressions