activeinsights 0.3.1 → 0.3.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: e533b9e56ed98672b949403f1ad4ae1b533832abbea5376a6d225b1f73ae14f4
4
- data.tar.gz: 20bfedf00b6b878643db9adce6d6608791dd1f0b1a0402219490d7d19cc5d104
3
+ metadata.gz: 7688455ff2b9d8559c34b1ccc49c45c97c8614d84804ecb023cff48f84d6d377
4
+ data.tar.gz: b85987b97b44ffc28ca19fe39c94277a5691e89096367ab79c9ae9a76f216a68
5
5
  SHA512:
6
- metadata.gz: f1701580b1caff352a81e719f03e42b18365602c4904926a9d7da1076b44c417a6c416f7c78eb16b04bba158b157affe0d8a011a154cf97d6207bd023e1f2879
7
- data.tar.gz: d4e7bbc7ab88d32c723991869909cf083edf40703f367adac38cc6f06fdd73d139de6bfad2758f086e6b688d07fb9394e07770844429ef650153dbc9289cc49a
6
+ metadata.gz: ff708ca0e904e3f7f6ea4b46d2a3b39b08c7e5aa4af0fa63abd5245e32d5b28b5f6ee1e4ffe412c30e0bb43721ffe52932024083e6632211e4ac2d0fa08d77e8
7
+ data.tar.gz: 8801288b6d0790beb7e37c0597ee86da476e53b676f371b8bd99604ac28a7c9039e9738abd48ebdd1ff92151bde984ad52c4d155e86eb43ac593e8457c5c0fbb
@@ -10,7 +10,12 @@ module ActiveInsights
10
10
  end
11
11
 
12
12
  before_validation do
13
- self.queue_time ||= (started_at - scheduled_at) * 1000.0
13
+ self.queue_time ||=
14
+ if scheduled_at.blank?
15
+ 0.0
16
+ else
17
+ (started_at - scheduled_at) * 1000.0
18
+ end
14
19
  end
15
20
  end
16
21
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ActiveInsights
4
- VERSION = "0.3.1"
4
+ VERSION = "0.3.2"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: activeinsights
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.1
4
+ version: 0.3.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nick Pezza