public function expires($time)
{
if (!empty($time) && is_string($time) && !($timestamp = strtotime($time))) {
throw new \Ergo\Routing\Exception("Invalid expiry time: {$timestamp}");
} else {
if (is_numeric($time)) {
$timestamp = $time;
} else {
if ($time == false) {
return $this;
}
}
}
$this->addHeader('Expires', date('r', $timestamp));
return $this;
}