Skip to content

Commit 049ef37

Browse files
committed
Change thread validation to if thread_count > 1
1 parent 12b82a8 commit 049ef37

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/duckdb/connection.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ def register_scalar_function(scalar_function)
181181
result = execute("SELECT current_setting('threads')")
182182
thread_count = result.first.first.to_i
183183

184-
unless thread_count == 1
184+
if thread_count > 1
185185
raise DuckDB::Error,
186186
"Scalar functions with Ruby callbacks require single-threaded execution. " \
187187
"Current threads setting: #{thread_count}. " \

0 commit comments

Comments
 (0)