Fixes a bad http error crash

In commit c84e5768 a then method was introduced which unknowingly
exposed a bug.

When a fila or then method returns a value (or undefined / no value) the
resulting promise is fulfilled. When chaining this could be a disaster.

this commit moves the fail method to the bottom of the chain to catch
all possible problems.