[rebuild] Call MODx.logout() when trying to logout

Fixes #11646