Fix .update_all and .delete_all when using a condition on a joined table
in a default_scope.

`Model.joins(...).where(condition_on_joined_table).update_all` /
`delete_all` worked, but the same operation implemented with a
default_scope generated a SQL error because ActiveRecord ignored the
join but implemented the where condition anyways.
Merge pull request #8994 from Springest/fix_default_scope_update_all_delete_all

Fix .update_all and .delete_all when using a condition on a joined table in a default_scope