Remove unnecessary error check in canonical example