Service/MpdfService.php
private function validateFormat($format)
    {
        if (is_array($format) && count($format) == 2) {
            $validatedFormat = array();
            foreach ($format as $length) {
                $validatedFormat[] = (float)$length;
            }

            return $validatedFormat;
        }
        if (in_array(strtoupper($format), $this->getAcceptedFormats())) {
            return $format;
        }

        return 'A4';
    }
private function validateFormat($format)
    {
        if (is_array($format) && count($format) == 2) {
            $validatedFormat = array();
            foreach ($format as $length) {
                $validatedFormat[] = (float)$length;
            }

            return $validatedFormat;
        }
        if (in_array(strtoupper($format), $this->getAcceptedFormats())) {
            return $format;
        }

        return 'A4';
    }
@param $format

@return array|string