# Applying virtual background error

**URL:** <https://openvidu.discourse.group/t/applying-virtual-background-error/4844>\
**Category:** How to implement?\
**Tags:** v2\
**Created:** [November 7, 2023, 11:16am UTC](https://openvidu.discourse.group/t/applying-virtual-background-error/4844 "2023-11-07T11:16:53Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![jkar](https://yyz2.discourse-cdn.com/free1/user_avatar/openvidu.discourse.group/jkar/32/2230_2.png) [@jkar](https://openvidu.discourse.group/u/jkar)\
**Post date:** [November 7, 2023, 11:16am UTC](https://openvidu.discourse.group/t/applying-virtual-background-error/4844/1 "2023-11-07T11:16:54Z")

</div>

Hi,  
We have functionality where it is possible to switch between virtual backgrounds.  
This works as expected in all other devices but iOS. With iOS this errors appears:

> Error applying filter for Stream str\_id - AbortError: The operation was aborted.

This error comes when there is filter active and another filter is selected and code to switch filter is like below.

```auto
await publisher.stream
            .removeFilter()
            .then(
              async () => await publisher.stream.applyFilter('VB:blur', {})
            );

```

After error, filter can be activated instantly in iOS device also. With other devices code above works, it removes existing filter and set a new one.

Can you spot what we might doing wrong here?

Edit: same behaviour happens only in iOS devices when filter is active and page is reloaded and we’re trying to apply the filter again.
