public function getImageVariation($user, $imageIdentifier, $width) { $variationPath = $this->getImagePath($user, $imageIdentifier, $width); if (file_exists($variationPath)) { return file_get_contents($variationPath); } return null; }