photo-helper 0.5.1 → 0.5.2
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/Gemfile.lock +1 -1
- data/lib/helpers/smugmug_album.rb +2 -1
- data/lib/helpers/smugmug_api.rb +7 -0
- data/lib/photo-helper/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 0feaba25fffb7634e816f16e80f11666cd6b18add7654d49cbd94bee690038ff
|
|
4
|
+
data.tar.gz: 6b76c47719929fe25c68373585ce2365a6d8b8e25606e4f3985e5ac8c1016f53
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: e8051f0f5b37c43c75ecf88efffa7aa6e0aaecd10c699e1f596472b3372e87634348468e1241f935684d4b43bcc437f4c769f8c78a2980507c890a0720192d3b
|
|
7
|
+
data.tar.gz: de34bb8a932d4714c830447655f9563817c4500705dd37360952a0f9f6f1fe0d912351d42fece858afbe71eaa4f76d89bb2f3274b6a09dbe043900ddf6d5a5f0
|
data/Gemfile.lock
CHANGED
|
@@ -236,7 +236,6 @@ class SmugmugAlbumHelper
|
|
|
236
236
|
@dl_uploaded_hash ||= uploaded_to_hash(@dl_album)
|
|
237
237
|
|
|
238
238
|
to_collect = []
|
|
239
|
-
# no_match = {}
|
|
240
239
|
|
|
241
240
|
@image_list.each do |filename, images|
|
|
242
241
|
images.each do |image|
|
|
@@ -249,6 +248,8 @@ class SmugmugAlbumHelper
|
|
|
249
248
|
end
|
|
250
249
|
end
|
|
251
250
|
|
|
251
|
+
# delete all images from album since we just collec them anyways which is cheap
|
|
252
|
+
@smugmug.delete_images(@smugmug.images(@album[:id]))
|
|
252
253
|
@smugmug.collect_images(to_collect, @album[:id])
|
|
253
254
|
end
|
|
254
255
|
|
data/lib/helpers/smugmug_api.rb
CHANGED
|
@@ -159,6 +159,13 @@ class SmugmugAPI
|
|
|
159
159
|
images
|
|
160
160
|
end
|
|
161
161
|
|
|
162
|
+
def delete_images(images)
|
|
163
|
+
images = [images] unless images.is_a? Array
|
|
164
|
+
images.each do |image|
|
|
165
|
+
http(:delete, image[:uri])
|
|
166
|
+
end
|
|
167
|
+
end
|
|
168
|
+
|
|
162
169
|
def image_list(album_id)
|
|
163
170
|
@images = images(album_id)
|
|
164
171
|
@images.map { |i| i[:filename] }
|
data/lib/photo-helper/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: photo-helper
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.5.
|
|
4
|
+
version: 0.5.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Benjamin Caldwell
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2018-06-
|
|
11
|
+
date: 2018-06-19 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: bundler
|