Index: Source/modules/webdatabase/SQLTransaction.cpp |
diff --git a/Source/modules/webdatabase/SQLTransaction.cpp b/Source/modules/webdatabase/SQLTransaction.cpp |
index 31a6605d36e5dd9e5d4f14ee97032f92a789056c..b00fbcdac6e1ec74eb6f22a838dbe16afe127191 100644 |
--- a/Source/modules/webdatabase/SQLTransaction.cpp |
+++ b/Source/modules/webdatabase/SQLTransaction.cpp |
@@ -269,7 +269,7 @@ void SQLTransaction::performPendingCallback() |
runStateMachine(); |
} |
-void SQLTransaction::executeSQL(const String& sqlStatement, const Vector<SQLValue>& arguments, SQLStatementCallback* callback, SQLStatementErrorCallback* callbackError, ExceptionState& exceptionState) |
+void SQLTransaction::executeSql(ScriptState* scriptState, const String& sqlStatement, const Nullable<Vector<ScriptValue>>& arguments, SQLStatementCallback* callback, SQLStatementErrorCallback* callbackError, ExceptionState& exceptionState) |
{ |
if (!m_executeSqlAllowed) { |
exceptionState.throwDOMException(InvalidStateError, "SQL execution is disallowed."); |
@@ -288,7 +288,16 @@ void SQLTransaction::executeSQL(const String& sqlStatement, const Vector<SQLValu |
permissions |= DatabaseAuthorizer::ReadOnlyMask; |
SQLStatement* statement = SQLStatement::create(m_database.get(), callback, callbackError); |
- m_backend->executeSQL(statement, sqlStatement, arguments, permissions); |
+ Vector<SQLValue> sqlValues; |
+ if (!arguments.isNull()) |
+ sqlValues = toImplArray<SQLValue>(arguments.get(), scriptState->isolate(), exceptionState); |
+ |
+ m_backend->executeSQL(statement, sqlStatement, sqlValues, permissions); |
+} |
+ |
+void SQLTransaction::executeSql(ScriptState* scriptState, const String& sqlStatement, ExceptionState& exceptionState) |
+{ |
+ executeSql(scriptState, sqlStatement, Vector<ScriptValue>(), nullptr, nullptr, exceptionState); |
} |
bool SQLTransaction::computeNextStateAndCleanupIfNeeded() |