Ok, I sorta get it and I sorta don't.
I see a lot of statements like this:
scope :tutor_role, ->{with_role("tutor")}
scope :chapter_leader_role, ->{with_role("chapter_leader")}
scope :teacher_role, ->{with_role("teacher")}
My basic understanding of using scope as written above is that it's a way to limit the data retrieved from the database, ie, very specific data.
Is that a correct understanding of scopes?
EDIT
Before anyone else comments that this is a duplicate again, and I don't necessarily disagree with that assessment, there were several reasons why I had asked this question.
One of the reasons why I had stuck that example code in this post is that I was also confused about "with_role" in the context of the scope statements.
What is that? I didn't see that in other scoping questions, hence I thought I would go ahead with this question.