[ATTACHMENTS] Add event 'AttachmentFileInfo' to allow a plugin to override the file displayed

This commit is contained in:
2021-04-28 15:01:40 +00:00
parent 708a910870
commit 2adb3c3521
2 changed files with 15 additions and 6 deletions

View File

@@ -161,8 +161,8 @@ class GSFile
*/
public static function getAttachmentFileInfo(int $id): array
{
$res = self::getFileInfo($id);
$res['file_path'] = Common::config('attachments', 'dir') . $res['file_hash'];
$res = self::getFileInfo($id);
$res['filepath'] = Common::config('attachments', 'dir') . $res['file_hash'];
return $res;
}