refactoring name of success variable