Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dol_add_file_process : return nb of success in case of multiple added… #32027

Merged
Merged
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
4 changes: 2 additions & 2 deletions htdocs/core/lib/files.lib.php
Original file line number Diff line number Diff line change
Expand Up @@ -1888,7 +1888,7 @@ function dol_init_file_process($pathtoscan = '', $trackid = '')
* @param int<0,1> $generatethumbs 1=Generate also thumbs for uploaded image files
* @param ?Object $object Object used to set 'src_object_*' fields
* @param string $forceFullTestIndexation '1'=Force full text storage in database even if global option not set (consume a high level of data)
* @return int Return integer <=0 if KO, >0 if OK
* @return int Return integer <=0 if KO, nb of success if OK (>0)
* @see dol_remove_file_process()
*/
function dol_add_file_process($upload_dir, $allowoverwrite = 0, $updatesessionordb = 0, $varfiles = 'addedfile', $savingdocmask = '', $link = null, $trackid = '', $generatethumbs = 1, $object = null, $forceFullTestIndexation = '')
Expand Down Expand Up @@ -2031,7 +2031,7 @@ function dol_add_file_process($upload_dir, $allowoverwrite = 0, $updatesessionor
}
}
if ($nbok > 0) {
$res = 1;
$res = $nbok;
setEventMessages($langs->trans("FileTransferComplete"), null, 'mesgs');
}
} else {
Expand Down
Loading