summaryrefslogtreecommitdiff
path: root/src/mongo/shell/mongo.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/shell/mongo.js')
-rw-r--r--src/mongo/shell/mongo.js6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/mongo/shell/mongo.js b/src/mongo/shell/mongo.js
index 6b5891bf3ee..41f5b1fe978 100644
--- a/src/mongo/shell/mongo.js
+++ b/src/mongo/shell/mongo.js
@@ -149,10 +149,6 @@ Mongo.prototype.getReadPrefTagSet = function () {
return this._readPrefTagSet;
};
-var isArray = function(maybeArray) {
- return Object.prototype.toString.call(maybeArray) === '[object Array]';
-};
-
// Returns a readPreference object of the type expected by mongos.
Mongo.prototype.getReadPref = function () {
var obj = {}, mode, tagSet;
@@ -164,7 +160,7 @@ Mongo.prototype.getReadPref = function () {
}
// Server Selection Spec: - if readPref mode is "primary" then the tags field MUST
// be absent. Ensured by setReadPref.
- if (isArray(tagSet = this.getReadPrefTagSet())) {
+ if (Array.isArray(tagSet = this.getReadPrefTagSet())) {
obj.tags = tagSet;
}