removed unnecessary anonymous function