Skip to content

Commit

Permalink
Specified LSCWP in adv-cache compatible file.
Browse files Browse the repository at this point in the history
  • Loading branch information
Hai Zheng committed Feb 14, 2024
1 parent 4f293d0 commit d74dfa6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/activation.cls.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
<?php

/**
* The plugin activation class.
*
Expand All @@ -8,6 +9,7 @@
* @subpackage LiteSpeed/inc
* @author LiteSpeed Technologies <info@litespeedtech.com>
*/

namespace LiteSpeed;

defined('WPINC') || exit();
Expand Down Expand Up @@ -45,7 +47,7 @@ public static function register_activation()
$advanced_cache = LSCWP_CONTENT_DIR . '/advanced-cache.php';
if (version_compare($wp_version, '5.3', '<') && !file_exists($advanced_cache)) {
$file_pointer = fopen($advanced_cache, 'w');
fwrite($file_pointer, "<?php\n\n// A compatibility placeholder for WordPress < v5.3\n");
fwrite($file_pointer, "<?php\n\n// A compatibility placeholder for WordPress < v5.3\n// Created by LSCWP v6.1+");
fclose($file_pointer);
}

Expand Down

0 comments on commit d74dfa6

Please sign in to comment.