Fix undefined function in example

The name of the function is being logged, but the function is not defined in the example.