safe errors in ensure method