From 176923148cc038e34890eaf4a6b0e32dd7138ead Mon Sep 17 00:00:00 2001
From: Susanne Moog <susanne.moog@typo3.org>
Date: Sun, 17 Jun 2018 17:12:38 +0200
Subject: [PATCH] [BUGFIX] Cast uid from database to int in TableWizard

Resolves: #85294
Releases: master
Change-Id: Id15a7dc0896a7031272ef5dde41606aaebaaec9c
Reviewed-on: https://review.typo3.org/57250
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Oliver Klee <typo3-coding@oliverklee.de>
Reviewed-by: Benni Mack <benni@typo3.org>
Tested-by: Benni Mack <benni@typo3.org>
Reviewed-by: Georg Ringer <georg.ringer@gmail.com>
Tested-by: Georg Ringer <georg.ringer@gmail.com>
---
 .../backend/Classes/Controller/Wizard/TableController.php     | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/typo3/sysext/backend/Classes/Controller/Wizard/TableController.php b/typo3/sysext/backend/Classes/Controller/Wizard/TableController.php
index 4febd5f74dde..32701eda7c14 100644
--- a/typo3/sysext/backend/Classes/Controller/Wizard/TableController.php
+++ b/typo3/sysext/backend/Classes/Controller/Wizard/TableController.php
@@ -449,7 +449,7 @@ class TableController extends AbstractWizardController
                 $bodyText = $this->configurationArrayToString($this->TABLECFG['c']);
                 // Create cfgArr from the string based configuration - that way it is cleaned up
                 // and any incompatibilities will be removed!
-                $configuration = $this->configurationStringToArray($bodyText, $row[$this->colsFieldName]);
+                $configuration = $this->configurationStringToArray($bodyText, (int)$row[$this->colsFieldName]);
             }
             // If a save button has been pressed, then save the new field content:
             if ($_POST['_savedok'] || $_POST['_saveandclosedok']) {
@@ -494,7 +494,7 @@ class TableController extends AbstractWizardController
                 } else {
                     // Regular line based table configuration:
                     $columns = $row[$this->colsFieldName] ?? 0;
-                    $configuration = $this->configurationStringToArray($row[$this->P['field']], $columns);
+                    $configuration = $this->configurationStringToArray($row[$this->P['field']], (int)$columns);
                 }
             }
             $configuration = is_array($configuration) ? $configuration : [];
-- 
GitLab