@@ -101,15 +101,15 @@ local function processSmartCollectionQueue(smartColls, publishService, propertyT
101101 if not smartColls or index > # smartColls then
102102 releasePublishLock (serviceId )
103103 progressScope :done ()
104- LrDialogs .message (" Clone completed" , " Publish Service Clone omplete ." , " info" )
104+ LrDialogs .message (" Clone completed" , " Publish Service Clone Complete ." , " info" )
105105 return
106106 end
107107
108108 local entry = smartColls [index ]
109109 if not entry then
110110 releasePublishLock (serviceId )
111111 progressScope :done ()
112- LrDialogs .message (" Clone completed" , " Publish Service Clone omplete ." , " info" )
112+ LrDialogs .message (" Clone completed" , " Publish Service Clone Complete ." , " info" )
113113 return -- done
114114 end
115115
@@ -362,7 +362,7 @@ local function createTree(nodes, parentSet, publishService, created, childrenInd
362362 if extra then
363363 if extra .collSettings then
364364 comment = extra .collSettings .comment or " "
365- status = extra .collSettings .status or " "
365+ status = extra .collSettings .status or " public "
366366 end
367367 isSmartColl = extra .isSmartColl
368368 searchDesc = extra .searchDesc
@@ -388,22 +388,36 @@ local function createTree(nodes, parentSet, publishService, created, childrenInd
388388 local collectionSettings = newCollorSet :getCollectionSetInfoSummary ().collectionSettings or {}
389389 if propertyTable .syncAlbumDescriptions then
390390 collectionSettings .albumDescription = comment
391- collectionSettings .albumPrivate = status == " private"
392391 else
393392 collectionSettings .albumDescription = " "
393+ end
394+ if status == " private" then
395+ collectionSettings .albumPrivate = true
396+ else
394397 collectionSettings .albumPrivate = false
395398 end
399+
396400 if remoteAlbumId then
397401 local thisCat = PiwigoAPI .pwCategoriesGetThis (propertyTable , remoteAlbumId )
398402 if thisCat then
399- if thisCat .name == name then
400- albumUrl = propertyTable .host .. " /index.php?/category/" .. remoteAlbumId
401- catalog :withWriteAccessDo (" Add Piwigo details to collections" , function ()
402- newCollorSet :setRemoteId (remoteAlbumId )
403- newCollorSet :setRemoteUrl (albumUrl )
404- newCollorSet :setCollectionSetSettings (collectionSettings )
405- end )
403+ if propertyTable .syncAlbumDescriptions then
404+ if thisCat .description then
405+ collectionSettings .albumDescription = thisCat .description
406+ else
407+ collectionSettings .albumDescription = " "
408+ end
409+ end
410+ if thisCat .status == " public" then
411+ collectionSettings .albumPrivate = false
412+ else
413+ collectionSettings .albumPrivate = true
406414 end
415+ albumUrl = propertyTable .host .. " /index.php?/category/" .. remoteAlbumId
416+ catalog :withWriteAccessDo (" Add Piwigo details to collections" , function ()
417+ newCollorSet :setRemoteId (remoteAlbumId )
418+ newCollorSet :setRemoteUrl (albumUrl )
419+ newCollorSet :setCollectionSetSettings (collectionSettings )
420+ end )
407421 end
408422 end
409423 end
@@ -464,6 +478,18 @@ local function createTree(nodes, parentSet, publishService, created, childrenInd
464478 -- check if remoote album exists and add to collection if so
465479 local thisCat = PiwigoAPI .pwCategoriesGetThis (propertyTable , remoteAlbumId )
466480 if thisCat then
481+ if propertyTable .syncAlbumDescriptions then
482+ if thisCat .description then
483+ collectionSettings .albumDescription = thisCat .description
484+ else
485+ collectionSettings .albumDescription = " "
486+ end
487+ end
488+ if thisCat .status == " public" then
489+ collectionSettings .albumPrivate = false
490+ else
491+ collectionSettings .albumPrivate = true
492+ end
467493 albumUrl = propertyTable .host .. " /index.php?/category/" .. remoteAlbumId
468494 catalog :withWriteAccessDo (" Add Piwigo details to collections" , function ()
469495 newCollorSet :setRemoteId (remoteAlbumId )
0 commit comments