Skip to content

Commit

Permalink
fix(multisite): reset Database instance on blog switch
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaucau committed Dec 18, 2024
1 parent 6201895 commit b64076e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Orm/Database.php
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ public function __construct()

// Add hook to update prefix when switching between blogs in multisite
add_action('switch_blog', function () {
$this->setTablePrefix($this->db->prefix);
self::$instance = null;
});
}

Expand Down

0 comments on commit b64076e

Please sign in to comment.