Skip to content

Commit

Permalink
opcache
Browse files Browse the repository at this point in the history
opcache invalidation
  • Loading branch information
erichk4 committed Jun 19, 2019
1 parent 5b16b6f commit 24d1160
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions pomodoro.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,14 @@ public function __construct( $mofile, $domain, $override ) {
if ( $this->busted ) {
file_put_contents( $cache_file, sprintf( '<?php $_mtime = %d; $_cache = %s;', $mtime, var_export( $_this->cache, true ) ), LOCK_EX );
}

/**
* opcache_invalidate
*/
if ( function_exists('opcache_is_script_cached') && opcache_is_script_cached( $cache_file ) )
{
opcache_invalidate( $cache_file, true );
}
} );
}

Expand Down

0 comments on commit 24d1160

Please sign in to comment.