small refactoring (added the newExpense scope attribute)