Small refactoring on invite