protected function updateMainImageSize()
	{
		// Get path to main image
		$pathToMainImage = public_path() . \Config::get('laravel-pages::main_image_resized_dir') . $this->main_image;
		if (is_file($pathToMainImage) && file_exists($pathToMainImage))
		{
			list($width, $height) = getimagesize($pathToMainImage);
		}
		else
		{
			$width = $height = null;
		}
		// Update the database, use DB::table()->update approach so as not to trigger the Eloquent save() event again.
		\DB::table($this->getTable())
			->where('id', $this->id)
			->update(array(
				'main_image_width' => $width,
				'main_image_height' => $height,
			));
	}