diff --git a/native_mate/arguments.h b/native_mate/arguments.h index 493af7c63bf6..701b5fecae49 100644 --- a/native_mate/arguments.h +++ b/native_mate/arguments.h @@ -36,8 +36,11 @@ class Arguments { insufficient_arguments_ = true; return false; } - v8::Local val = (*info_)[next_++]; - return ConvertFromV8(isolate_, val, out); + v8::Local val = (*info_)[next_]; + bool success = ConvertFromV8(isolate_, val, out); + if (success) + next_++; + return success; } template