From aa7f4f2e108a96c10fa35973871c9483f5775d52 Mon Sep 17 00:00:00 2001
From: putro <putro@autistici.org>
Date: Sat, 28 Oct 2023 14:12:57 +0200
Subject: [PATCH] do not remove metadata from pdf - and commit...

---
 wp-mat.php | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/wp-mat.php b/wp-mat.php
index bf9ecbe..4d8c3e6 100644
--- a/wp-mat.php
+++ b/wp-mat.php
@@ -26,10 +26,12 @@ class WP_Mat {
 
     // Check if the mime type is one of those we want to clean up.
     // Use a blacklist, currently empty. Send everything by default
-    // except video.
+    // except video, and pdf.
     function is_supported_mime_type($mimetype) {
         if (substr($mimetype, 0, 6) === "video/") {
             return false;
+        if (substr($mimetype, 0, 15) === "application/pdf") {
+            return false;
         }
         return true;
     }
-- 
GitLab