Skip to content

Commit

Permalink
Merge pull request #19 from chibiegg/fix-when-empty-album-list
Browse files Browse the repository at this point in the history
Verify whether the response is empty
  • Loading branch information
stanaka authored Aug 24, 2018
2 parents 8576194 + f0002ce commit c9bef42
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions google-photo.lrplugin/GPhotoAPI.lua
Original file line number Diff line number Diff line change
Expand Up @@ -377,6 +377,9 @@ function GPhotoAPI.listAlbums(propertyTable)
local json = require 'json'
local results = json.decode(result)
nextPageToken = results["nextPageToken"]
if not results.albums then
break
end
for i,v in ipairs(results.albums) do
albums[#albums+1] = v
end
Expand Down

0 comments on commit c9bef42

Please # to comment.