Skip to content

Commit bd1af62

Browse files
committed
Remove workaround for "false" return value
1 parent a06eeb4 commit bd1af62

File tree

2 files changed

+1
-6
lines changed

2 files changed

+1
-6
lines changed

activerecord-sqlserver-adapter.gemspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,5 +28,5 @@ Gem::Specification.new do |spec|
2828
spec.require_paths = ["lib"]
2929

3030
spec.add_dependency "activerecord", "~> 8.1.0.alpha"
31-
spec.add_dependency "tiny_tds"
31+
spec.add_dependency "tiny_tds", "~> 3"
3232
end

lib/active_record/connection_adapters/sqlserver/database_statements.rb

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -461,13 +461,8 @@ def finish_statement_handle(handle)
461461
handle
462462
end
463463

464-
# TinyTDS returns false instead of raising an exception if connection fails.
465-
# Getting around this by raising an exception ourselves while PR
466-
# https://github.com/rails-sqlserver/tiny_tds/pull/469 is not released.
467464
def internal_raw_execute(sql, raw_connection, perform_do: false)
468465
result = raw_connection.execute(sql)
469-
raise TinyTds::Error, "failed to execute statement" if result.is_a?(FalseClass)
470-
471466
perform_do ? result.do : result
472467
end
473468
end

0 commit comments

Comments
 (0)