diff options
author | Maxence Lange <maxence@artificial-owl.com> | 2019-05-17 09:19:45 -0100 |
---|---|---|
committer | Maxence Lange <maxence@artificial-owl.com> | 2019-05-17 09:19:45 -0100 |
commit | ec822a440bbc9b81005921c6430640d5388e5289 (patch) | |
tree | d18c239a7dd38679001ffd5747f2b3988aa0b58f /lib/Model/ActivityPub/Stream.php | |
parent | 1ad4d54ac76c54def69158669dd785dad3d2233e (diff) |
cleaning code
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
Diffstat (limited to 'lib/Model/ActivityPub/Stream.php')
-rw-r--r-- | lib/Model/ActivityPub/Stream.php | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/lib/Model/ActivityPub/Stream.php b/lib/Model/ActivityPub/Stream.php index 42ac756b..7b081148 100644 --- a/lib/Model/ActivityPub/Stream.php +++ b/lib/Model/ActivityPub/Stream.php @@ -212,12 +212,13 @@ class Stream extends ACore implements JsonSerializable { } /** - * - * @throws Exception */ public function convertPublished() { - $dTime = new DateTime($this->getPublished()); - $this->setPublishedTime($dTime->getTimestamp()); + try { + $dTime = new DateTime($this->getPublished()); + $this->setPublishedTime($dTime->getTimestamp()); + } catch (Exception $e) { + } } @@ -289,8 +290,6 @@ class Stream extends ACore implements JsonSerializable { /** * @param array $data - * - * @throws Exception */ public function import(array $data) { parent::import($data); |