removed E (error) generic parameter

refined the demo code to use => (then)