Skip to content

Commit

Permalink
Merge pull request #308 from samvera-labs/private_members
Browse files Browse the repository at this point in the history
Move member_ids to private visibility
  • Loading branch information
Trey Pendragon authored Nov 13, 2017
2 parents 886035e + fcb8827 commit 54e0af2
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions valkyrie/lib/valkyrie/persistence/memory/query_service.rb
Original file line number Diff line number Diff line change
Expand Up @@ -84,17 +84,18 @@ def find_parents(resource:)
end
end

def member_ids(resource:)
return [] unless resource.respond_to? :member_ids
resource.member_ids || []
end

def custom_queries
@custom_queries ||= ::Valkyrie::Persistence::CustomQueryContainer.new(query_service: self)
end

private

# @return [Array<Valkyrie::ID>] a list of the identifiers of the member objects
def member_ids(resource:)
return [] unless resource.respond_to? :member_ids
resource.member_ids || []
end

def validate_id(id)
raise ArgumentError, 'id must be a Valkyrie::ID' unless id.is_a? Valkyrie::ID
end
Expand Down

0 comments on commit 54e0af2

Please sign in to comment.