---
title: "updateContentFilter(_:completionHandler:)"
framework: screencapturekit
role: symbol
role_heading: Instance Method
path: "screencapturekit/scstream/updatecontentfilter(_:completionhandler:)"
---

# updateContentFilter(_:completionHandler:)

Updates the stream by applying a new content filter.

## Declaration

```swift
func updateContentFilter(_ contentFilter: SCContentFilter, completionHandler: (@Sendable ((any Error)?) -> Void)? = nil)
```

```swift
func updateContentFilter(_ contentFilter: SCContentFilter) async throws
```

## Parameters

- `contentFilter`: The content filter to apply.
- `completionHandler`: A completion handler the system calls when this method completes. It includes an error if the update fails.

## See Also

### Updating stream configuration

- [updateConfiguration(_:completionHandler:)](screencapturekit/scstream/updateconfiguration(_:completionhandler:).md)
