Fixed the example

This didn't compile due to all the recent public API changes.