public function update(Media $media)
    {
        $storage = $this->filesystem->disk($media->disk);

        $media->size = $this->verifyFileSize($storage->size($media->getDiskPath()));
        $media->mime_type = $this->verifyMimeType($storage->mimeType($media->getDiskPath()));
        $media->aggregate_type = $this->inferAggregateType($media->mime_type, $media->extension);

        if ($dirty = $media->isDirty()) {
            $media->save();
        }

        return $dirty;
    }