From be3514c36fc3b0707ad85a25110a0e32aa2863e5 Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Mon, 13 Sep 2021 18:02:39 +0200 Subject: [PATCH] preferring get_rrows over get_rows to fix SQL error in timesheet merge --- api/src/Storage/Merge.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/api/src/Storage/Merge.php b/api/src/Storage/Merge.php index 451e61f019..b7bd67868a 100644 --- a/api/src/Storage/Merge.php +++ b/api/src/Storage/Merge.php @@ -2472,8 +2472,8 @@ abstract class Merge return $ui->get_all_ids(); } - // Try cache - if( method_exists($ui_class, 'get_rows')) + // Try cache, preferring get_rrows over get_rows + if (method_exists($ui_class, $get_rows='get_rrows') || method_exists($ui_class, $get_rows='get_rows')) { foreach($locations as $location) { @@ -2486,7 +2486,7 @@ abstract class Merge $rows = $readonlys = array(); @set_time_limit(0); // switch off the execution time limit, as it's for big selections to small $session['num_rows'] = -1; // all - $ui->get_rows($session, $rows, $readonlys); + $ui->$get_rows($session, $rows, $readonlys); foreach($rows as $row_number => $row) { if(!is_numeric($row_number)) continue;