README.md: Fix error handling in example