calendar_sniper 1.1.5 → 1.1.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/calendar_sniper/version.rb +1 -1
- data/lib/calendar_sniper.rb +3 -3
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2a643990fd3e526ea5589431a2c219ea7f769c46
|
4
|
+
data.tar.gz: 0ee2f43c4afabdc0baa0a4cbc0902c2ee8667921
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c78f91f0375c5630566cbee8621377c13dddae522e1f3028edea7e4272b1b30cec5ac01d5af2ea38b5d8b87f330820ccaadcb9bf36e4f5f5057454a12191ff55
|
7
|
+
data.tar.gz: d224f0d54c09ace2862dc518223238ec46223d8e27dfdfef918a7e0dae4530ca923692f7a11c0718d4aaad128b1cf1a26a6521e021f3a25254d56a69140cb1b2
|
data/lib/calendar_sniper.rb
CHANGED
@@ -13,11 +13,11 @@ module CalendarSniper
|
|
13
13
|
when /\A\d+(?:\.\d+)?\z/
|
14
14
|
with_from_date(num_days.to_f.days.ago)
|
15
15
|
when 'today'
|
16
|
-
where(
|
16
|
+
where(created_at: Date.today.beginning_of_day..Time.now)
|
17
17
|
when 'yesterday'
|
18
|
-
where(
|
18
|
+
where(created_at: Date.yesterday.beginning_of_day..Date.yesterday.end_of_day)
|
19
19
|
when 'last_month'
|
20
|
-
where(
|
20
|
+
where(created_at: 1.month.ago.beginning_of_month..1.month.ago.end_of_month)
|
21
21
|
else
|
22
22
|
fail "Unknown date range for filtering: #{num_days}"
|
23
23
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: calendar_sniper
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Chris MacNaughton
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2017-01-
|
12
|
+
date: 2017-01-05 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activesupport
|