public function transform($value)
{
if ($value === null) {
return '';
}
if (!$value instanceof \DateTime) {
throw new \InvalidArgumentException('Expected value of type \DateTime');
}
$value->setTimezone(new \DateTimeZone($this->getOption('output_timezone')));
return $value->format($this->getOption('format'));
}