Skip to content

[Rails5] Fix snippets_finder arel queries

blackst0ne requested to merge blackst0ne-rails5-fix-snippets-finder into master

What does this MR do?

There is a bug in Rails 5.0 and 5.1 in Arel/ActiveRecord.
This MR converts arel based queries to their raw counterparts to make the finder work in Rails 5.0.

These changes should be reverted when we're on Rails 5.2 as since that version such queries work well again.

We've already faced this problem before.

Are there points in the code the reviewer needs to double check?

Check if SQL queries are OK.

Why was this MR needed?

Migration to Rails 5.0.

Screenshots (if relevant)

No.

Does this MR meet the acceptance criteria?

What are the relevant issue numbers?

Closes #47832 (closed)

Edited by Yorick Peterse

Merge request reports