in2code-de / luxletter

Newsletter system for TYPO3
https://www.in2code.de/agentur/typo3-extensions/luxletter/
24 stars 25 forks source link

[BUGFIX] Adjust SQL definition to fulfill mysql strict mode #116

Closed magicHatOfTYPO3 closed 2 years ago

magicHatOfTYPO3 commented 2 years ago

Resolves: #115

I first thought of a major incompatibility with PHP8.0, but it seems that only the SQL definition of the TEXT and MEDIUMTEXT fields is the cause.

Since TEXT fields in MySQL do not have a default value, but these fields are probably not necessarily set explicitly, but must not be NULL, the following behavior occurs. Tested with PHP8.0 and TYPO3 11LTS, but I assume, the problem might also occur on systems with PHP 7.* as I think the violation against the MySQL/MariaDB strict mode is the cause for the problem.

As TEXT fields can't have a default value in MySQL/MariaDB and the value is not being set explicitly in every cause, you have to allow NULL as it's value. Maybe TYPO3 11/PHP 8.0 is there more strict in throwing errors.

einpraegsam commented 2 years ago

Thx for your time that you spent while digging into that issue