Refactoring buttons