Updated to latest anonymous function syntax