From ec2388860141dcde6387f4cba482955de648e5aa Mon Sep 17 00:00:00 2001 From: Samuel Gaist Date: Wed, 27 Sep 2017 23:18:52 +0200 Subject: Doc: fix QJSEngine code snippet The code snippet showing how to use QJSValue::call was wrong. This patch corrects that. Change-Id: Ib4c6479f3ef63f4f95af845d0af228d3c71f0731 Reviewed-by: Sze Howe Koh --- src/qml/doc/snippets/code/src_script_qjsengine.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/qml/doc/snippets/code/src_script_qjsengine.cpp') diff --git a/src/qml/doc/snippets/code/src_script_qjsengine.cpp b/src/qml/doc/snippets/code/src_script_qjsengine.cpp index 0305574d34..11e1c76f8b 100644 --- a/src/qml/doc/snippets/code/src_script_qjsengine.cpp +++ b/src/qml/doc/snippets/code/src_script_qjsengine.cpp @@ -48,7 +48,7 @@ QJSValue three = myEngine.evaluate("1 + 2"); QJSValue fun = myEngine.evaluate("(function(a, b) { return a + b; })"); QJSValueList args; args << 1 << 2; -QJSValue threeAgain = fun.call(QJSValue(), args); +QJSValue threeAgain = fun.call(args); //! [1] -- cgit v1.2.3