]> BookStack Code Mirror - bookstack/blobdiff - app/Http/RangeSupportedStream.php
Tests: Updated comment test to account for new editor usage
[bookstack] / app / Http / RangeSupportedStream.php
index fce1e9acce30cbc187756c5ef9dd54b7e79f51dd..c4b00778939dd00fd20a762520051c4436be5d40 100644 (file)
@@ -32,12 +32,12 @@ class RangeSupportedStream
     /**
      * Sniff a mime type from the stream.
      */
-    public function sniffMime(): string
+    public function sniffMime(string $extension = ''): string
     {
         $offset = min(2000, $this->fileSize);
         $this->sniffContent = fread($this->stream, $offset);
 
-        return (new WebSafeMimeSniffer())->sniff($this->sniffContent);
+        return (new WebSafeMimeSniffer())->sniff($this->sniffContent, $extension);
     }
 
     /**