mk-j / PHP_XLSXWriter

Lightweight XLSX Excel Spreadsheet Writer in PHP
MIT License
1.84k stars 665 forks source link

Incompatible to PHP 5.2.1 #278

Closed breti closed 4 years ago

breti commented 4 years ago

Incompatible to PHP 5.2.1 because ?: is used without the middle part. That's available with PHP 5.3+:

https://www.php.net/manual/en/language.operators.comparison.php

"The expression (expr1) ? (expr2) : (expr3) evaluates to expr2 if expr1 evaluates to TRUE, and expr3 if expr1 evaluates to FALSE.

Since PHP 5.3, it is possible to leave out the middle part of the ternary operator. Expression expr1 ?: expr3 returns expr1 if expr1 evaluates to TRUE, and expr3 otherwise. "

mk-j commented 4 years ago

okay this is fixed in master now.

breti commented 4 years ago

Thanks!