mirror of
https://github.com/shlinkio/shlink.git
synced 2025-02-25 18:45:27 -06:00
Fixed date format returned by the API
This commit is contained in:
@@ -84,7 +84,7 @@ class ListKeysCommand extends Command
|
||||
$rowData[] = $this->{$formatMethod}($this->getEnabledSymbol($row));
|
||||
}
|
||||
|
||||
$rowData[] = isset($expiration) ? $expiration->format(\DateTime::ISO8601) : '-';
|
||||
$rowData[] = isset($expiration) ? $expiration->format(\DateTime::ATOM) : '-';
|
||||
$table->addRow($rowData);
|
||||
}
|
||||
|
||||
|
||||
@@ -176,7 +176,7 @@ class ShortUrl extends AbstractEntity implements \JsonSerializable
|
||||
return [
|
||||
'shortCode' => $this->shortCode,
|
||||
'originalUrl' => $this->originalUrl,
|
||||
'dateCreated' => isset($this->dateCreated) ? $this->dateCreated->format(\DateTime::ISO8601) : null,
|
||||
'dateCreated' => isset($this->dateCreated) ? $this->dateCreated->format(\DateTime::ATOM) : null,
|
||||
'visitsCount' => count($this->visits),
|
||||
'tags' => $this->tags->toArray(),
|
||||
];
|
||||
|
||||
@@ -171,7 +171,7 @@ class Visit extends AbstractEntity implements \JsonSerializable
|
||||
{
|
||||
return [
|
||||
'referer' => $this->referer,
|
||||
'date' => isset($this->date) ? $this->date->format(\DateTime::ISO8601) : null,
|
||||
'date' => isset($this->date) ? $this->date->format(\DateTime::ATOM) : null,
|
||||
'remoteAddr' => $this->remoteAddr,
|
||||
'userAgent' => $this->userAgent,
|
||||
'visitLocation' => $this->visitLocation,
|
||||
|
||||
Reference in New Issue
Block a user