Contacts - Attachments: Fix download and image display.

This commit is contained in:
fusionate 2024-09-27 11:30:53 -06:00
parent 28ddb69fe1
commit afa0b91b15
No known key found for this signature in database
1 changed files with 3 additions and 2 deletions

View File

@ -42,9 +42,10 @@
$sql .= "where contact_attachment_uuid = :contact_attachment_uuid ";
$sql .= "and (domain_uuid = :domain_uuid or domain_uuid is null) ";
$parameters['contact_attachment_uuid'] = $contact_attachment_uuid;
$parameters['domain_uuid'] = $domain_uuid;
$parameters['domain_uuid'] = $_SESSION['domain_uuid'];
$database = new database;
$attachment = $database->select($sql, $parameters ?? null, 'row');
// view_array($database->message);
unset($sql, $parameters);
$attachment_type = strtolower(pathinfo($attachment['attachment_filename'] ?? '', PATHINFO_EXTENSION));
@ -78,4 +79,4 @@
}
?>
?>