jenkins-bot has submitted this change and it was merged.
Change subject: Add fallback for gzdecode (only exists in PHP >= 5.4.0)
......................................................................
Add fallback for gzdecode (only exists in PHP >= 5.4.0)
Bug: 54058
Change-Id: I62a843aec4657a3d4895d34535cc2be42d4552fd
---
M TemplateData.php
1 file changed, 8 insertions(+), 0 deletions(-)
Approvals:
Catrope: Looks good to me, approved
jenkins-bot: Verified
diff --git a/TemplateData.php b/TemplateData.php
index 159729f..0dec3b1 100644
--- a/TemplateData.php
+++ b/TemplateData.php
@@ -48,3 +48,11 @@
'localBasePath' => $dir,
'remoteExtPath' => 'TemplateData',
);
+
+// gzdecode function only exists in PHP >= 5.4.0
+// http://php.net/manual/en/function.gzdecode.php
+if ( !function_exists( 'gzdecode' ) ) {
+ function gzdecode( $data ) {
+ return gzinflate( substr( $data, 10, -8 ) );
+ }
+}
--
To view, visit https://gerrit.wikimedia.org/r/83981
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I62a843aec4657a3d4895d34535cc2be42d4552fd
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/TemplateData
Gerrit-Branch: master
Gerrit-Owner: Reedy <[email protected]>
Gerrit-Reviewer: Catrope <[email protected]>
Gerrit-Reviewer: Krinkle <[email protected]>
Gerrit-Reviewer: jenkins-bot
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits