Can you add a check on the error value of this?