mirror of
https://github.com/prasathmani/tinyfilemanager
synced 2026-03-16 13:45:48 +01:00
fix config save opcache delay
If you had opcache installed, settings changes would not be immediately applied, leading to the >Sometimes the save action may not work on the first try, so please attempt it again. text. Opcache is bundled in php core as of php5.5.0, compiled by default in php-fpm, and is a very popular extension. It's basically ubiquitous.
This commit is contained in:
parent
7e7fb1f505
commit
f816bd8b04
1 changed files with 4 additions and 2 deletions
|
|
@ -1639,8 +1639,6 @@ if (isset($_GET['settings']) && !FM_READONLY) {
|
|||
<button type="submit" class="btn btn-success"> <i class="fa fa-check-circle"></i> <?php echo lng('Save'); ?></button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<small class="text-body-secondary">* <?php echo lng('Sometimes the save action may not work on the first try, so please attempt it again') ?>.</span>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -3691,7 +3689,11 @@ class FM_Config
|
|||
for ($x = 3; $x < count($lines); $x++) {
|
||||
@fputs($fh, $lines[$x], strlen($lines[$x]));
|
||||
}
|
||||
@fflush($fh);
|
||||
@fclose($fh);
|
||||
if (is_callable("opcache_invalidate")) {
|
||||
@opcache_invalidate($fm_file, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue