[phpMyAdmin Git] [phpmyadmin/phpmyadmin] 1270ef: Refactor util.php (#17212)

Kamil Tekiela tekiela246 at gmail.com
Thu Dec 2 21:37:11 CET 2021


Branch: refs/heads/master
Home: https://github.com/phpmyadmin/phpmyadmin
Commit: 1270efc2a9205f5160262ecbd33558203f9e21a1
https://github.com/phpmyadmin/phpmyadmin/commit/1270efc2a9205f5160262ecbd33558203f9e21a1
Author: Kamil Tekiela <tekiela246 at gmail.com>
Date: 2021-12-02 (Thu, 12 December 2021) -03:00

Changed paths: 
M libraries/classes/Controllers/Table/ZoomSearchController.php
M libraries/classes/Display/Results.php
M libraries/classes/InsertEdit.php
M libraries/classes/Plugins/Export/ExportSql.php
M libraries/classes/Util.php
M phpstan-baseline.neon
M psalm-baseline.xml
M test/classes/Display/ResultsTest.php
M test/classes/UtilTest.php

Log Message:
-----------
Refactor util.php (#17212)

* Remove extra space

Signed-off-by: Kamil Tekiela <tekiela246 at gmail.com>

* Remove null checks on properties that cannot be null

The value could be null only if the property exists in stdClass
returned by mysqli but is null. Mysqli doesn't do that. Unless the value
can be null in some other way, this check is redundant.

Signed-off-by: Kamil Tekiela <tekiela246 at gmail.com>

* Add psalm-return

Signed-off-by: Kamil Tekiela <tekiela246 at gmail.com>

* Remove $handle parameter of getUniqueCondition()

Signed-off-by: Kamil Tekiela <tekiela246 at gmail.com>

* Type hint the $row parameter

Signed-off-by: Kamil Tekiela <tekiela246 at gmail.com>

Co-authored-by: Maurício Meneghini Fauth <mauricio at fauth.dev>



More information about the Git mailing list