fixing bug with error propogation for futures returned from a `then` callback