```val maybeClient = Either.monad<DataBaseFailu...
# arrow
n
Copy code
val maybeClient = Either.monad<DataBaseFailure>().binding {
                        val ip = Option.fromNullable(System.getenv("MONGODB_IP")).toEither { DataBaseFailure(report) }.bind()
                        val cl = Option.fromNullable(MongoClient(ip, 27017)).toEither { DataBaseFailure(report) }.bind()
                        yields(cl)
                    }.ev()