Instead of warning, you can completely ignore cases when the scope include order/offset/limit or you can raise an exception instead.
This change is actually a performance improvment. Avoiding arel calls to identify it default scope has order/offset/limit is time consuming and we don't need to verify it every time we boot.
Additional option of raising an exception might be useful for tests to prevent defining scopes with ordering or pagination.
Before submitting the PR make sure the following are checked:
[x] The PR relates to only one subject with a clear title and description in grammatically correct, complete sentences.
Instead of warning, you can completely ignore cases when the scope include order/offset/limit or you can raise an exception instead.
This change is actually a performance improvment. Avoiding
arel
calls to identify it default scope has order/offset/limit is time consuming and we don't need to verify it every time we boot.Additional option of raising an exception might be useful for tests to prevent defining scopes with ordering or pagination.
Before submitting the PR make sure the following are checked:
[Fix #issue-number]
(if the related issue exists).master
(if not - rebase it).