Fixed lambda replacement function.