Skip to content

Commit

Permalink
General: (umpirsky) Work Item PHPOfficeGH-548 - Optimize vlookup() sort
Browse files Browse the repository at this point in the history
  • Loading branch information
MarkBaker committed May 24, 2015
1 parent 1ba2ae0 commit e4d2982
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Classes/PHPExcel/Calculation/LookupRef.php
Original file line number Diff line number Diff line change
Expand Up @@ -674,10 +674,10 @@ private static function vlookupSort($a, $b)
{
reset($a);
$firstColumn = key($a);
if (strtolower($a[$firstColumn]) == strtolower($b[$firstColumn])) {
if (($aLower = strtolower($a[$firstColumn])) == ($bLower = strtolower($b[$firstColumn]))) {
return 0;
}
return (strtolower($a[$firstColumn]) < strtolower($b[$firstColumn])) ? -1 : 1;
return ($aLower < $bLower) ? -1 : 1;
}


Expand Down
1 change: 1 addition & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
Planned for 1.8.2
- Bugfix: (MBaker) - Fix to getCell() method when cell reference includes a worksheet reference
- Bugfix: (ncrypthic) Work Item GH-570 - Ignore inlineStr type if formula element exists
- General: (umpirsky) Work Item GH-548 - Optimize vlookup() sort


2015-04-30 (v1.8.1):
Expand Down

0 comments on commit e4d2982

Please sign in to comment.