recordPublishedPhotoId and with setPropertyForPlugin before that
Hello,
I'm building my first Lightroom plugin and i'm having trouble dealing with processRenderedPhotos(). Images are being uploaded to a service (RESTful API) and the service response contains some metadata I need to set to the photo. I'm doing:
photo.catalog:withWriteAccessDo( "publishing", function( context )
-- bla bla, image was uploaded
photo:setPropertyForPlugin( _PLUGIN, "someKey", "someValue" )
rendition:recordPublishedPhotoId( remoteIdend )
The problem is that by calling photo:setPropertyForPlugin(), my image goes into the "Modified Photos to Re-Publish" queue instead of being in the "Published" one. If i don't call the setPropertyForPlugin() method, the image is moved into the "Published photos" section.
I belive the withWriteAccessDo() has a delay and my rendition:recordPublishedPhotoId() call is actually performed BEFORE the writes to the LrPhoto object, hence the moving of that image to the "modified" queue (sometimes I can even see the UI shoing the image in the "Published" queue and then it refreshes and moves into the modified one).
Please help ![]()
Thank you!