fraggle 0.3.0 → 0.3.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.
- data/lib/fraggle/snap.rb +6 -5
- data/test/fraggle_client_test.rb +1 -1
- data/test/fraggle_protocol_test.rb +1 -1
- data/test/fraggle_snap_test.rb +1 -1
- metadata +2 -2
data/lib/fraggle/snap.rb
CHANGED
@@ -4,11 +4,12 @@ module Fraggle
|
|
4
4
|
|
5
5
|
class Snap
|
6
6
|
|
7
|
-
attr_reader :id
|
7
|
+
attr_reader :id, :rev, :c
|
8
8
|
|
9
|
-
def initialize(id, c)
|
10
|
-
@id
|
11
|
-
@c
|
9
|
+
def initialize(id, c, rev=nil)
|
10
|
+
@id = id
|
11
|
+
@c = c
|
12
|
+
@rev = rev
|
12
13
|
end
|
13
14
|
|
14
15
|
def get(path, &blk)
|
@@ -29,7 +30,7 @@ module Fraggle
|
|
29
30
|
|
30
31
|
def snap(&blk)
|
31
32
|
@c.snap do |res|
|
32
|
-
sn = Snap.new(res.id, @c)
|
33
|
+
sn = Snap.new(res.id, @c, res.rev)
|
33
34
|
blk.call(sn)
|
34
35
|
end
|
35
36
|
end
|
data/test/fraggle_client_test.rb
CHANGED
data/test/fraggle_snap_test.rb
CHANGED