From 8fd5954351200e1fdc94c3d2ad67478230d0bd45 Mon Sep 17 00:00:00 2001 From: Morgan Aubert Date: Tue, 26 Dec 2023 13:58:15 -0500 Subject: [PATCH] Fix compilation error with Crystal nightly --- src/marten/db/query/sql/predicate/base.cr | 2 +- src/marten/db/query/sql/predicate_node.cr | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/marten/db/query/sql/predicate/base.cr b/src/marten/db/query/sql/predicate/base.cr index 75fd88ac6..754689cca 100644 --- a/src/marten/db/query/sql/predicate/base.cr +++ b/src/marten/db/query/sql/predicate/base.cr @@ -36,7 +36,7 @@ module Marten connection.operator_for(self.class.predicate_name) % "%s" end - private def sql_right_operand_param(_connection) + private def sql_right_operand_param(_connection) : ::DB::Any @left_operand.to_db(@right_operand.as(Field::Any)) end end diff --git a/src/marten/db/query/sql/predicate_node.cr b/src/marten/db/query/sql/predicate_node.cr index 7e6ef2338..c81ed5ec5 100644 --- a/src/marten/db/query/sql/predicate_node.cr +++ b/src/marten/db/query/sql/predicate_node.cr @@ -58,7 +58,7 @@ module Marten def to_sql(connection : Connection::Base) sql_parts = [] of String - sql_params = [] of Field::Any + sql_params = [] of ::DB::Any @predicates.each do |predicate| predicate_sql, predicate_params = predicate.to_sql(connection)