rworktracker 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (2) hide show
  1. data/lib/rworktracker.rb +5 -1
  2. metadata +2 -2
data/lib/rworktracker.rb CHANGED
@@ -168,7 +168,11 @@ class RworkTracker
168
168
  @wdata[pro].each_value do |m|
169
169
  m.each_value do |d|
170
170
  d.each do |e|
171
- total += Time.parse(e['stop']) - Time.parse(e['start'])
171
+ if e['stop']
172
+ total += Time.parse(e['stop']) - Time.parse(e['start'])
173
+ elsif started?(pro)
174
+ total += Time.now - Time.parse(e['start'])
175
+ end
172
176
  end
173
177
  end
174
178
  end
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: rworktracker
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.0.1
5
+ version: 0.0.2
6
6
  platform: ruby
7
7
  authors:
8
8
  - ghedamat
@@ -90,7 +90,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
90
90
  requirements:
91
91
  - - ">="
92
92
  - !ruby/object:Gem::Version
93
- hash: -321784013
93
+ hash: 50633839
94
94
  segments:
95
95
  - 0
96
96
  version: "0"