protected function checkFormat($format, $type = null) { return !is_null($format) ? $format : $this->getFormat($type); }