Partial revert of 73c883c due to issues with handlers in roles

Fixes #6322