From 384a841ef86e642f37866ad99a5541fb0d0a8d74 Mon Sep 17 00:00:00 2001 From: Felix Arntz Date: Mon, 18 Nov 2024 08:22:37 -0800 Subject: [PATCH] Update function docs to clarify attachment specific scope. --- plugins/webp-uploads/helper.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/plugins/webp-uploads/helper.php b/plugins/webp-uploads/helper.php index 175d32117..972091ae2 100644 --- a/plugins/webp-uploads/helper.php +++ b/plugins/webp-uploads/helper.php @@ -470,8 +470,9 @@ function webp_uploads_get_mime_type_image( int $attachment_id, string $src, stri } /** - * Retrieves the MIME type of a file, checking the file directly if possible, - * and falling back to the attachment's MIME type if needed. + * Retrieves the MIME type of an attachment file, checking the file directly if possible. + * + * If checking the file directly fails, the function falls back to the attachment's MIME type. * * The function attempts to determine the MIME type directly from the file. * If that information is unavailable, it uses the MIME type from the attachment metadata.