refactoring + add button