diff options
author | n-peugnet <n.peugnet@free.fr> | 2020-04-24 16:36:12 +0200 |
---|---|---|
committer | Vincent Peugnet <33429034+vincent-peugnet@users.noreply.github.com> | 2020-04-25 17:44:38 +0200 |
commit | 385b3f4adf86606e03941171c136d8f2eb2b35c2 (patch) | |
tree | 2231cf04d67a5cae7284364ac5552a321b9a236e /app/class/Modeltimeline.php | |
parent | 03d425bdd9a639446ae72ce6556d753f2f162f83 (diff) | |
download | wcms-385b3f4adf86606e03941171c136d8f2eb2b35c2.tar.gz wcms-385b3f4adf86606e03941171c136d8f2eb2b35c2.zip |
fix: most of PHPStan errors
Diffstat (limited to 'app/class/Modeltimeline.php')
-rw-r--r-- | app/class/Modeltimeline.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/app/class/Modeltimeline.php b/app/class/Modeltimeline.php index db9c4f5..be80211 100644 --- a/app/class/Modeltimeline.php +++ b/app/class/Modeltimeline.php @@ -19,7 +19,7 @@ class Modeltimeline extends Modeldb public function get(int $id) { - $eventdata = $this->repo->findById($id); + $eventdata = $this->repo->findById("$id"); if ($eventdata !== false) { return new Event($eventdata); } else { @@ -62,7 +62,7 @@ class Modeltimeline extends Modeldb /** * Store event * - * @param Event The event to be stored in the repositery + * @param Event $event The event to be stored in the repositery * * @return bool retrun true if it works, false if it fails */ @@ -97,6 +97,7 @@ class Modeltimeline extends Modeldb $id = 0; $subid = 0; $lastuser = null; + $groupedevents = []; foreach ($events as $event) { if ($event->user() !== $lastuser) { $subid = 0; |