You are here

protected function TinyPngImageHandler::isMimeSupported in TinyPNG 8

Check if given mime is supported.

Parameters

string $mime: Mime type to check.

Return value

bool Returns TRUE if given mime type string is supported.

1 call to TinyPngImageHandler::isMimeSupported()
TinyPngImageHandler::checkFile in src/TinyPngImageHandler.php
Check if given file entity is an image with a supported type.

File

src/TinyPngImageHandler.php, line 218

Class

TinyPngImageHandler
Class TinyPngImageHandler.

Namespace

Drupal\tinypng

Code

protected function isMimeSupported($mime) {
  return in_array($mime, $this->supportedMimeTypes);
}