rename scope

This commit is contained in:
Torsten 2023-01-30 19:00:45 +02:00
parent 2305577e9d
commit a45016f539
2 changed files with 2 additions and 2 deletions

View File

@ -3,7 +3,7 @@ class MembersController < ApplicationController
# GET /members # GET /members
def index def index
@members = Member.public.order(:name).page params[:page] @members = Member.public_scope.order(:name).page params[:page]
end end
# GET /members/1 # GET /members/1

View File

@ -1,6 +1,6 @@
class Member < ApplicationRecord class Member < ApplicationRecord
def self.public def self.public_scope
where.not(confirmed_at: nil).where.not(picture: nil) where.not(confirmed_at: nil).where.not(picture: nil)
end end