Backward-compatible fix for deprecation warning when using Model#scoped