You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tinkerpop.apache.org by sp...@apache.org on 2018/10/05 12:37:03 UTC

[02/10] tinkerpop git commit: Refactor of RemoteStrategy apply()

Refactor of RemoteStrategy apply()


Project: http://git-wip-us.apache.org/repos/asf/tinkerpop/repo
Commit: http://git-wip-us.apache.org/repos/asf/tinkerpop/commit/c04ddae8
Tree: http://git-wip-us.apache.org/repos/asf/tinkerpop/tree/c04ddae8
Diff: http://git-wip-us.apache.org/repos/asf/tinkerpop/diff/c04ddae8

Branch: refs/heads/TINKERPOP-1959
Commit: c04ddae8a5793177d7515629358346d91be73e43
Parents: b6478d6
Author: Matthew Allen <ma...@runbox.com>
Authored: Fri Aug 24 16:14:29 2018 +0100
Committer: Matthew Allen <ma...@runbox.com>
Committed: Fri Aug 24 16:14:29 2018 +0100

----------------------------------------------------------------------
 .../gremlin-javascript/lib/driver/remote-connection.js          | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/c04ddae8/gremlin-javascript/src/main/javascript/gremlin-javascript/lib/driver/remote-connection.js
----------------------------------------------------------------------
diff --git a/gremlin-javascript/src/main/javascript/gremlin-javascript/lib/driver/remote-connection.js b/gremlin-javascript/src/main/javascript/gremlin-javascript/lib/driver/remote-connection.js
index d93d89b..96db161 100644
--- a/gremlin-javascript/src/main/javascript/gremlin-javascript/lib/driver/remote-connection.js
+++ b/gremlin-javascript/src/main/javascript/gremlin-javascript/lib/driver/remote-connection.js
@@ -74,9 +74,8 @@ class RemoteStrategy extends TraversalStrategy {
     let args = null;
 
     // check if the last instruction is an eval statement
-    const bytecode = traversal.getBytecode();
-    if (bytecode.stepInstructions.length && bytecode.stepInstructions[bytecode.stepInstructions.length-1][0] === 'eval') {
-      const script = traversal.getBytecode().toScript();
+    if (instructions.stepInstructions.length && instructions.stepInstructions[instructions.stepInstructions.length-1][0] === 'eval') {
+      const script = instructions.toScript();
       op = 'eval';
       processor = '';
       args = {