From 26c98440b29a4c0330d318d592a76733c8b410aa Mon Sep 17 00:00:00 2001 From: Nick Taylor Date: Thu, 12 Dec 2019 16:04:22 -0500 Subject: [PATCH] Escape strings in RemoveClause Currently in RemoveClause only symbols are escaped with backticks, meaning that using `.remove` will fail on labels with special characters. This can be encountered with a namespaced label name, such as MyModule::MyThing. --- lib/neo4j/core/query_clauses.rb | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/lib/neo4j/core/query_clauses.rb b/lib/neo4j/core/query_clauses.rb index 6988a51b..4621c541 100644 --- a/lib/neo4j/core/query_clauses.rb +++ b/lib/neo4j/core/query_clauses.rb @@ -643,9 +643,7 @@ def from_key_and_value(key, value) case value when /^:/ "#{key}:`#{value[1..-1]}`" - when String - "#{key}.#{value}" - when Symbol + when String, Symbol "#{key}:`#{value}`" when Array value.map do |v|