---
title: "filterSections(matching:memberOf:)"
framework: musickit
role: symbol
role_heading: Instance Method
path: "musickit/musiclibrarysectionedrequest/filtersections(matching:memberof:)-746mb"
---

# filterSections(matching:memberOf:)

Filters sections by an optional property for an array of possible values.

## Declaration

```swift
mutating func filterSections<Value>(matching keyPath: KeyPath<SectionType.LibraryFilter, Value?>, memberOf values: [Value?]) where SectionType : MusicLibraryRequestable, Value : MusicLibraryRequestFilterValueMembershipComparable
```
