Test the README example code and update README with a fix