send notification mail when new attachment was added

This commit is contained in:
Uwe Steinmann 2021-08-30 19:35:08 +02:00
parent 33c10fc1db
commit 13ad0788a3

View File

@ -896,6 +896,9 @@ switch($command) {
header('Content-Type: application/json'); header('Content-Type: application/json');
echo json_encode(array('success'=>false, 'message'=>getMLText('error_occured'), 'data'=>'')); echo json_encode(array('success'=>false, 'message'=>getMLText('error_occured'), 'data'=>''));
} else { } else {
if($notifier) {
$notifier->sendNewFileMail($res, $user);
}
header('Content-Type: application/json'); header('Content-Type: application/json');
echo json_encode(array('success'=>true, 'message'=>getMLText('splash_document_added'), 'data'=>$document->getID())); echo json_encode(array('success'=>true, 'message'=>getMLText('splash_document_added'), 'data'=>$document->getID()));
add_log_line(); add_log_line();