Fix API of example code

This briefly tripped me up.
Merge pull request #180 from blittle/master

Fix API of example code