diff options
author | Kaloian Manassiev <kaloian.manassiev@mongodb.com> | 2016-02-18 11:54:42 -0500 |
---|---|---|
committer | Kaloian Manassiev <kaloian.manassiev@mongodb.com> | 2016-02-18 11:58:32 -0500 |
commit | 808fc26a78c1c0132019768a24c1060f56e4b7f2 (patch) | |
tree | 6250164f04d2534b6f87bdde4a952d5c3450dd75 /src/mongo/scripting/mozjs/valuewriter.cpp | |
parent | 3e17e22b60cdca796bb04ffd5ef82cbf7af34d26 (diff) | |
download | mongo-808fc26a78c1c0132019768a24c1060f56e4b7f2.tar.gz |
SERVER-9131 Fix lint failed checks
Diffstat (limited to 'src/mongo/scripting/mozjs/valuewriter.cpp')
-rw-r--r-- | src/mongo/scripting/mozjs/valuewriter.cpp | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/src/mongo/scripting/mozjs/valuewriter.cpp b/src/mongo/scripting/mozjs/valuewriter.cpp index 967a2947cd8..8767c7e83ac 100644 --- a/src/mongo/scripting/mozjs/valuewriter.cpp +++ b/src/mongo/scripting/mozjs/valuewriter.cpp @@ -267,17 +267,16 @@ void ValueWriter::_writeObject(BSONObjBuilder* b, } if (scope->getProto<CodeInfo>().getJSClass() == jsclass) { - if (o.hasOwnField(InternedString::scope) // CodeWScope - && o.type(InternedString::scope) == mongo::Object) { - + if (o.hasOwnField(InternedString::scope) // CodeWScope + && + o.type(InternedString::scope) == mongo::Object) { if (o.type(InternedString::code) != mongo::String) { uasserted(ErrorCodes::BadValue, "code must be a string"); } - b->appendCodeWScope(sd, o.getString(InternedString::code), - o.getObject(InternedString::scope)); - } - else { // Code + b->appendCodeWScope( + sd, o.getString(InternedString::code), o.getObject(InternedString::scope)); + } else { // Code if (o.type(InternedString::code) != mongo::String) { uasserted(ErrorCodes::BadValue, "code must be a string"); } |