1
0
Fork 0
mirror of https://github.com/inretio/WordPress-Plugin-Boilerplate synced 2024-12-23 04:13:53 +02:00

Update activate_new_site did_action to become Yoda condition

This commit is contained in:
thuijssoon 2013-08-23 06:59:43 +02:00
parent 2a2050d7fb
commit 772e1365a5

View file

@ -165,7 +165,7 @@ class PluginName {
* @param int $blog_id ID of the new blog. * @param int $blog_id ID of the new blog.
*/ */
public function activate_new_site( $blog_id ) { public function activate_new_site( $blog_id ) {
if ( did_action( 'wpmu_new_blog' ) !== 1 ) if ( 1 !== did_action( 'wpmu_new_blog' ) )
return; return;
switch_to_blog( $blog_id ); switch_to_blog( $blog_id );