lib/solr_cloud/connection.rb in solr_cloud-connection-0.3.0 vs lib/solr_cloud/connection.rb in solr_cloud-connection-0.4.0
- old
+ new
@@ -176,11 +176,11 @@
# Solr only allows ASCII letters and numbers, underscore, and dash,
# and it can't start with an underscore.
# @param str [String] string to check
# @return [Boolean]
def legal_solr_name?(str)
- !(/[^a-zA-Z_\-0-9]/.match?(str) or str.start_with?("_"))
+ !(/[^a-zA-Z_\-.0-9]/.match?(str) or str.start_with?("-"))
end
def inspect
"<#{self.class} #{@url}>"
end
@@ -190,7 +190,8 @@
def pretty_print(q)
q.text inspect
end
end
end
+