plntr-fakes3 1.0.0.pre.11alpha1 → 1.0.0.pre.11alpha2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/fakes3/sorted_object_list.rb +5 -6
- data/lib/fakes3/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5d37f14e46d82b0fce9f7d75ee83ad54c14a18c74763da30fbe392af1b33477f
|
4
|
+
data.tar.gz: 73cb764c4888316a0ab7d660c55f8f67d77ee4f7d34553a6e02a899046264ed0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b42388884d9a328c554b99a7e87d39c1c1ee40303196bdca592b0f9cc608fdf8b7ddb932d27cefa5207b76edf082f6fc8c5416f0e5ff8a31087f778d907830b9
|
7
|
+
data.tar.gz: 889db612b67ab715d3cd5db5a123b6eb7005a0aba6e47713969e1022dd73c3929137526ccce46e97474a070d6dd81a5eb414887a845587d322560abd81f9afdb
|
@@ -56,10 +56,10 @@ module FakeS3
|
|
56
56
|
# :prefix : a string to filter the results by
|
57
57
|
# :delimiter : not supported yet
|
58
58
|
def list(options)
|
59
|
-
marker = options[:marker]
|
60
|
-
prefix = options[:prefix]
|
61
|
-
max_keys = options[:max_keys]
|
62
|
-
delimiter = options[:delimiter]
|
59
|
+
marker = options[:marker].length > 0 ? options[:marker] : nil
|
60
|
+
prefix = options[:prefix].length > 0 ? options[:prefix] : nil
|
61
|
+
max_keys = options[:max_keys] > 0 ? options[:max_keys] : 1000
|
62
|
+
delimiter = options[:delimiter].length > 0 ? options[:delimiter] : nil
|
63
63
|
|
64
64
|
ms = S3MatchSet.new
|
65
65
|
|
@@ -87,8 +87,7 @@ module FakeS3
|
|
87
87
|
last_chunk = nil
|
88
88
|
@sorted_set.each do |s3_object|
|
89
89
|
if marker_found && (!prefix or s3_object.name.index(prefix) == 0)
|
90
|
-
|
91
|
-
if delimiter and delimiter.length > 0
|
90
|
+
if delimiter
|
92
91
|
name = s3_object.name
|
93
92
|
remainder = name.slice(prefix_offset, name.length)
|
94
93
|
chunks = remainder.split(delimiter, 2)
|
data/lib/fakes3/version.rb
CHANGED