Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions album-songs.lua
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,7 @@ local res, code, response_headers, status, json_response, data = ampacheHttp.mak
})

-- Check if the request was successful
if code == 200 then

if code == 200 and data ~= nil then
-- if the -j option is passed, just print the json file
if is_json_output == true then
print(json_response)
Expand Down
2 changes: 1 addition & 1 deletion albums.lua
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ local res, code, response_headers, status, json_response, data =
filterValue = filter_value
})

if code == 200 then
if code == 200 and data ~= nil then
-- if the -j option is passed, just print the json file
if is_json_output == true then
print(json_response)
Expand Down