Some refactorings in actors