restforce-db 4.0.0 → 4.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/restforce/db/task_manager.rb +3 -1
- data/lib/restforce/db/tracker.rb +3 -7
- data/lib/restforce/db/version.rb +1 -1
- 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: eab3aaac473e45e0b8ab82cb1d9d9b3e9d1c17b2
|
4
|
+
data.tar.gz: a4e088c191e14afe9152790d43bca091e4210a49
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b19df3329f7e61688a59e8fb4b1b8b61b4c55c3204fd55c428f268364c8f9c74eaf1f993cba6bf14880776cba536a3373110653b8a8b318b5486aed458214029
|
7
|
+
data.tar.gz: 20ae363668dfcf76c8b8791bfa459d4125f690c589f22c0528d192e81050490d1bc10543f9bbab5499744b2c2188f8a0c4aaed929bfd7d06008c178665eed522
|
data/lib/restforce/db/tracker.rb
CHANGED
@@ -14,9 +14,9 @@ module Restforce
|
|
14
14
|
#
|
15
15
|
# file_path - The Path to the tracking file.
|
16
16
|
def initialize(file_path)
|
17
|
-
@
|
17
|
+
@file_path = file_path
|
18
18
|
|
19
|
-
timestamp = @file.read
|
19
|
+
timestamp = File.open(@file_path, "a+") { |file| file.read }
|
20
20
|
return if timestamp.empty?
|
21
21
|
|
22
22
|
@last_run = Time.parse(timestamp)
|
@@ -30,11 +30,7 @@ module Restforce
|
|
30
30
|
# Returns nothing.
|
31
31
|
def track(time)
|
32
32
|
@last_run = time
|
33
|
-
|
34
|
-
@file.truncate(0)
|
35
|
-
@file.print(time.utc.iso8601)
|
36
|
-
@file.flush
|
37
|
-
@file.rewind
|
33
|
+
File.open(@file_path, "w") { |file| file.write(time.utc.iso8601) }
|
38
34
|
end
|
39
35
|
|
40
36
|
end
|
data/lib/restforce/db/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: restforce-db
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.0.
|
4
|
+
version: 4.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Andrew Horner
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-08-
|
11
|
+
date: 2015-08-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord
|