lib/mongodb/graphite/agent/mongo_cient_extensions.rb in mongodb-graphite-agent-0.1.1 vs lib/mongodb/graphite/agent/mongo_cient_extensions.rb in mongodb-graphite-agent-0.1.2

- old
+ new

@@ -1,15 +1,15 @@ -module Mongo - - class MongoClient - def is_replicaset? - begin - cmd = BSON::OrderedHash.new - cmd["replSetGetStatus"] = 1 - result = self.db("admin").command(cmd) - return !result["set"].blank? - rescue Mongo::OperationFailure - return false - end - end - end -end +module Mongo + + class MongoClient + def is_replicaset? + begin + cmd = BSON::OrderedHash.new + cmd["replSetGetStatus"] = 1 + result = self.db("admin").command(cmd) + return !result["set"].blank? + rescue Mongo::OperationFailure + return false + end + end + end +end