Due to problems with my .htaccess file, I did found that Spots writes the complete .htaccess file every time a admin page is called. This behaviour is initiated from the action
add_action( 'do_once_icit_spots', 'flush_rewrite_rules' );
in line 30 of icit-spots.php (v1.0.7)
Is this really necessary? The documentation for function flush_rewrite_rules() states “Flushing the rewrite rules is an expensive operation, there are tutorials and examples that suggest executing it on the ‘init’ hook. This is bad practice.”
Perhaps you can restrict the call to this function when activating the plugin, or when you know that the rewrite rules need to be changed.
- The topic ‘[Plugin: Spots] Call of flush_rewrite_rules() always necessary?’ is closed to new replies.