fix return value - otherwise we get an error even when everything was alright