mirror of
https://gitlab.easter-eggs.com/ee/ldapsaisie.git
synced 2024-12-22 16:33:48 +01:00
Fix PHP 8.2 error on sorting values
This commit is contained in:
parent
bf1a3affe4
commit
dc8e08b5d1
3 changed files with 9 additions and 9 deletions
|
@ -187,11 +187,11 @@ class LSattr_html_select_list extends LSattr_html{
|
|||
* Function use with uasort to sort two values in ASC order
|
||||
*
|
||||
* @param string $va One value
|
||||
* @param string $va One value
|
||||
* @param string $vb Another value
|
||||
*
|
||||
* @return int Value for uasort
|
||||
**/
|
||||
protected static function _sortTwoValuesAsc(&$va,&$vb) {
|
||||
protected static function _sortTwoValuesAsc($va,$vb) {
|
||||
if (is_array($va)) {
|
||||
// Force sub-options at the end
|
||||
$nva='ZZZZ'.$va['label'];
|
||||
|
@ -217,11 +217,11 @@ class LSattr_html_select_list extends LSattr_html{
|
|||
* Function use with uasort to sort two values in DESC order
|
||||
*
|
||||
* @param string $va One value
|
||||
* @param string $va One value
|
||||
* @param string $vb Another value
|
||||
*
|
||||
* @return int Value for uasort
|
||||
**/
|
||||
protected static function _sortTwoValuesDesc(&$va,&$vb) {
|
||||
protected static function _sortTwoValuesDesc($va,$vb) {
|
||||
return (-1 * static :: _sortTwoValuesAsc($va,$vb));
|
||||
}
|
||||
|
||||
|
|
|
@ -149,11 +149,11 @@ class LSformElement_select_object extends LSformElement {
|
|||
* Function use with uasort to sort two values
|
||||
*
|
||||
* @param array $va One value
|
||||
* @param array $va One value
|
||||
* @param array $va Another value
|
||||
*
|
||||
* @return int Value for uasort
|
||||
**/
|
||||
private function _sortTwoValues(&$va,&$vb) {
|
||||
private function _sortTwoValues($va, $vb) {
|
||||
if ($this -> getParam('html_options.sortDirection') == 'DESC') {
|
||||
$dir=-1;
|
||||
}
|
||||
|
|
|
@ -1392,12 +1392,12 @@ class LSsearch extends LSlog_staticLoggerClass {
|
|||
/**
|
||||
* Function use with uasort to sort two entry
|
||||
*
|
||||
* @param LSsearchEntry &$a One entry of result
|
||||
* @param LSsearchEntry &$b One entry of result
|
||||
* @param LSsearchEntry $a One entry of result
|
||||
* @param LSsearchEntry $b Another entry of result
|
||||
*
|
||||
* @return int Value for uasort
|
||||
**/
|
||||
private function _sortTwoEntry(&$a,&$b) {
|
||||
private function _sortTwoEntry($a, $b) {
|
||||
$sortBy = $this -> params['sortBy'];
|
||||
$sortDirection = $this -> params['sortDirection'];
|
||||
if ($sortDirection=='ASC') {
|
||||
|
|
Loading…
Reference in a new issue