Details
-
Improvement
-
Resolution: Fixed
-
Major - P3
-
None
Description
Description
On this page there are some examples which I think could be simplified. As the most striking example, I think
db.players.find( {$expr: { $function: { |
body: function(userFn, doc) { return userFn.call(doc); }, |
args: [
|
function() { return hex_md5(this.name) == "15b0a220baa16331e8d80e15367677ad" ; }, |
"$$CURRENT" |
],
|
lang: "js" |
} } } )
|
Could be simplified into just
db.players.find( {$expr: { $function: { |
body: function(name) { return hex_md5(name) == "15b0a220baa16331e8d80e15367677ad"; }, |
args: [ "$name" ], |
lang: "js" |
} } } )
|