Refactoring: some generic actions.