title: Laravel File::mimeType memory issues
body: <p>There is an issue with one of my jobs, where I'm using a code block</p>
  <pre><code>$mimeType = \File::mimeType($localFile); // $localFile - absolute path of the file
  </code></pre>
  <p>This brings an memory issues with message below</p>
  <blockquote>
  <p>local.ERROR: Allowed memory size of 134217728 bytes exhausted (tried to allocate 156161944 bytes) {&quot;exception&quot;:&quot;[object] (Symfony\Component\Debug\Exception\FatalErrorException(code: 1): Allowed memory size of 134217728 bytes exhausted (tried to allocate 156161944 bytes) at /var/www/project/vendor/league/flysystem/src/Util/MimeType.php:209)</p>
  </blockquote>
  <p>It's clear, that by increasing memory limit this issue will be resolved, but I'm looking for something more, let's say flexible or elegant way of detecting file mime type like I have done for file upload to s3 and avoids memory issues using below code</p>
  <pre><code>$disk = Storage::disk('s3');
  $disk-&gt;put($path, fopen($localFile, 'r+'));
  </code></pre>
  <p>Is there any way to detect mime type without increasing memory limit?</p>
  <p>Thanks</p>