fix where on v8 SERVER-864
This commit is contained in:
@@ -382,14 +382,8 @@ namespace mongo {
|
||||
}
|
||||
|
||||
bool isSimpleStatement( const string& code ){
|
||||
{
|
||||
size_t x = code.find( "return" );
|
||||
if ( x != string::npos ){
|
||||
if ( ( x == 0 || ! isalpha( code[x-1] ) ) &&
|
||||
! isalpha( code[x+6] ) )
|
||||
return false;
|
||||
}
|
||||
}
|
||||
if ( hasJSReturn( code ) )
|
||||
return false;
|
||||
|
||||
if ( code.find( ";" ) != string::npos &&
|
||||
code.find( ";" ) != code.rfind( ";" ) )
|
||||
|
||||
Reference in New Issue
Block a user