public function setDimensions($width, $height) { if ((is_int($width) || ctype_digit($width)) && (is_int($height) || ctype_digit($height))) { $this->dimensions = [$width, $height]; } return $this; }