From 6efef82182aef5cc43c8eb6d4a9c2b0e8a4c431b Mon Sep 17 00:00:00 2001 From: Monique Date: Thu, 29 Sep 2022 11:25:03 +0200 Subject: [PATCH] foutmelding offset --- application/controllers/monpas/Rapontwikkel.php | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/application/controllers/monpas/Rapontwikkel.php b/application/controllers/monpas/Rapontwikkel.php index c9ef071..8b958ae 100644 --- a/application/controllers/monpas/Rapontwikkel.php +++ b/application/controllers/monpas/Rapontwikkel.php @@ -142,11 +142,12 @@ class Rapontwikkel extends MY_Controller { if ( $gewenst ) { $i = 0; - foreach ( $scores as $score ) - { - $score->gewenstid = $gewenst[ $i ]->id; - $score->gewenst = $gewenst[ $i ]->wens; + foreach ( $scores as $score ) { + if($gewenst[$i]){ + $score->gewenstid = $gewenst[$i]->id; + $score->gewenst = $gewenst[$i]->wens; $i = $i + 1; + } }; //foreach } }