Purchase : test $_FILES before trying to save file

This commit is contained in:
sparkyx 2025-10-06 16:37:32 +02:00
parent 9f3e308a21
commit 067434e520
2 changed files with 4 additions and 2 deletions

View file

@ -262,6 +262,9 @@ class Acc_Document extends Document {
/**
* pj is the $_FILES key
*/
if ( $_FILES['pj']['name']=="") {
return false;
}
$a_file= $this->db->upload('pj',only_oid:false);
if ($a_file == false) {
return false;