mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/SyntaxHighlight_GeSHi
synced 2024-11-15 02:24:07 +00:00
Allow "0" as the content of <syntaxhighlight>
The empty() function considers "0" to be empty. Makes empty() useless
for strings.
(cherry picked from commit 8d8fb22ebb
)
Bug: T41643
Change-Id: If0e647e3be269edcb23748d246bc564483aff0d2
This commit is contained in:
parent
966ed89270
commit
49044ad215
|
@ -595,10 +595,10 @@ class GeSHi {
|
|||
* @since 1.0.0
|
||||
*/
|
||||
function GeSHi($source = '', $language = '', $path = '') {
|
||||
if (!empty($source)) {
|
||||
if ($source !== '') {
|
||||
$this->set_source($source);
|
||||
}
|
||||
if (!empty($language)) {
|
||||
if ($language !== '') {
|
||||
$this->set_language($language);
|
||||
}
|
||||
$this->set_language_path($path);
|
||||
|
|
Loading…
Reference in a new issue