Upaded println to use logger.error instead