improved success-checking