Skip to content

Commit

Permalink
Merge pull request #1843 from Shopify/at-fix-active-record-relations-…
Browse files Browse the repository at this point in the history
…compiler

Fix ActiveRecordRelations compiler
  • Loading branch information
Morriar authored Mar 26, 2024
2 parents cc008be + 5fda757 commit a497082
Show file tree
Hide file tree
Showing 2 changed files with 695 additions and 1 deletion.
2 changes: 1 addition & 1 deletion lib/tapioca/dsl/compilers/active_record_relations.rb
Original file line number Diff line number Diff line change
Expand Up @@ -661,7 +661,7 @@ def create_common_methods
"::ActiveRecord::Type::Binary::Data, ::ActiveRecord::Type::Time::Value, Date, Time, " \
"::ActiveSupport::Duration, T::Class[T.anything])"
array_type = if constant.try(:composite_primary_key?)
"T::Array[T::Array[#{id_types}]"
"T::Array[T::Array[#{id_types}]]"
else
"T::Array[#{id_types}]"
end
Expand Down
Loading

0 comments on commit a497082

Please sign in to comment.