summaryrefslogtreecommitdiffstats
path: root/lib/Model/ActivityPub/Stream.php
diff options
context:
space:
mode:
authorMaxence Lange <maxence@artificial-owl.com>2019-05-17 09:19:45 -0100
committerMaxence Lange <maxence@artificial-owl.com>2019-05-17 09:19:45 -0100
commitec822a440bbc9b81005921c6430640d5388e5289 (patch)
treed18c239a7dd38679001ffd5747f2b3988aa0b58f /lib/Model/ActivityPub/Stream.php
parent1ad4d54ac76c54def69158669dd785dad3d2233e (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.php11
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);