Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(172)

Unified Diff: Source/bindings/modules/v8/custom/V8CustomSQLStatementErrorCallback.cpp

Issue 995203002: bindings: Add a macro for V8 Maybe<T> APIs. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/bindings/modules/v8/custom/V8CustomSQLStatementErrorCallback.cpp
diff --git a/Source/bindings/modules/v8/custom/V8CustomSQLStatementErrorCallback.cpp b/Source/bindings/modules/v8/custom/V8CustomSQLStatementErrorCallback.cpp
index 36a1cd84a54b801ce7ba002aa278fb393462c9cd..253d395cb77079bd5b3ea894170dda30e70036f1 100644
--- a/Source/bindings/modules/v8/custom/V8CustomSQLStatementErrorCallback.cpp
+++ b/Source/bindings/modules/v8/custom/V8CustomSQLStatementErrorCallback.cpp
@@ -31,6 +31,7 @@
#include "config.h"
#include "bindings/core/v8/ScriptController.h"
+#include "bindings/core/v8/V8Binding.h"
#include "bindings/modules/v8/V8SQLError.h"
#include "bindings/modules/v8/V8SQLStatementErrorCallback.h"
#include "bindings/modules/v8/V8SQLTransaction.h"
@@ -76,7 +77,11 @@ bool V8SQLStatementErrorCallback::handleEvent(SQLTransaction* transaction, SQLEr
// statement, if any, or onto the next overall step otherwise. Otherwise,
// the error callback did not return false, or there was no error callback.
// Jump to the last step in the overall steps.
- return exceptionCatcher.HasCaught() || (!result.IsEmpty() && result->BooleanValue());
+ if (exceptionCatcher.HasCaught())
+ return true;
+ bool value;
+ V8_CALL(value, result, BooleanValue(isolate->GetCurrentContext()), return true);
+ return value;
}
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698