Add documents to Zip plugin output not working as expected

I am trying to automatically download the zip file generated by the process model involving the "Add documents to Zip plugin". The process model is called from an user interface. 

In the process model I mapped the output of the plugin to a process variable called "newDocumentCreated".
In the interface I do the following:

                a!buttonWidget(
                  label: "Scarica Archivio",
                  icon: "download",
                  saveInto: a!startProcess(
                    processModel: cons!EDB_DOWNLOAD_ZIP,
                    processParameters: {
                      documents: ri!record.allegati,
                      documentPaths: rule!EDB_GetDocumentPath(
                        ri!record.allegati
                      ),
                      zipName: tostring(
                        ri!record.id
                      ) & "_Allegati.zip",
                      zipFolder: cons!EDB_UPLOADED_FOLDER
                    },
                    onSuccess: a!save(
                      local!pinfo, 
                      fv!processInfo.pv.newDocumentCreated & "ok"
                      
                    )
                  ),
                  style: "NORMAL",
                  showWhen: len(
                    local!selectedIndices
                  ) > 0
                ),

The problem is that I receive an empty document on the onSuccess callback, without Id or any other property. Despite this issue, the zip document is still created correctly.
I just cannot use it at the moment right after its creation in order to download it by the interface.

This is the text output of the document retrieved in "onSuccess" by fv!processInfo.pv.newDocumentCreated ---------> [Document:]

Am I missing something?

  Discussion posts and replies are publicly visible