[openmairie-framework-Commits] r5492 - openmairie_exemple/branches/4.11.0-compatibilite-php8.1_WIP3/core

0 views
Skip to first unread message

ldo...@users.adullact.net

unread,
Feb 26, 2026, 4:37:44 AM (8 days ago) Feb 26
to openmairie...@googlegroups.com
Author: ldorner
Date: 2026-02-26 10:37:41 +0100 (Thu, 26 Feb 2026)
New Revision: 5492

Modified:
openmairie_exemple/branches/4.11.0-compatibilite-php8.1_WIP3/core/om_application_pdo.trait.php
Log:
fix: reduction test pour cas booleen a null

Modified: openmairie_exemple/branches/4.11.0-compatibilite-php8.1_WIP3/core/om_application_pdo.trait.php
===================================================================
--- openmairie_exemple/branches/4.11.0-compatibilite-php8.1_WIP3/core/om_application_pdo.trait.php 2026-02-25 15:38:44 UTC (rev 5491)
+++ openmairie_exemple/branches/4.11.0-compatibilite-php8.1_WIP3/core/om_application_pdo.trait.php 2026-02-26 09:37:41 UTC (rev 5492)
@@ -1486,7 +1486,7 @@

if (!$get_columns_name && ($value === true || $value === false)) {
$boolean_columns[$key] = true;
- } else if (!$get_columns_name && ($value === 1 || $value === "1" || $value === "t" || $value === 0 || $value === "0" || $value === "f" || $value === "")) {
+ } else if (!$get_columns_name && ($value === 1 || $value === "1" || $value === "t" || $value === 0 || $value === "0" || $value === "f" || $value === null)) {
// Construire la map des métadonnées une seule fois
// à partir des tables de la requête (get_columns_metadata
// + get_additional_columns), évite getColumnMeta()
@@ -1528,7 +1528,7 @@
if (isset($boolean_columns[$lower_key])) {
if ($value === 1 || $value === "1" || $value === true) {
$value = "t";
- } elseif ($value === 0 || $value === "0" || $value === false || $value == "") {
+ } elseif ($value === 0 || $value === "0" || $value === false) {
$value = "f";
}
}

Reply all
Reply to author
Forward
0 new messages