# Do not start searching if query is empty \(\#9333\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/c015baa6385202af1a965c6346af71426c7e377e)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: c015baa6385202af1a965c6346af71426c7e377e

Requested commit: c015baa6385202af1a965c6346af71426c7e377e

Commit: c015baa6385202af1a965c6346af71426c7e377e

Tree: 813993cf90d6f9e39c7b40078a232d7e2fbc2ae0

Author: Thorsten Ball

Committer: GitHub

## Message

```
Do not start searching if query is empty (#9333)

This avoids the problem of a search being kicked off involuntarily and
potentially using a large amount of CPU when toggling on the `Search
Ignored Files` option.

What would happen is that someone would turn the option on, we'd kick
off a search, and go through all of the files in, say, `node_modules`.
Even if no query was given.

This avoids that.

Release Notes:

- Fixed an empty search being kicked off involuntarily if no query was
typed in yet but an option was toggled.
```

## Parents

- [f142568172972391df6ecae3a07f2e883013200e](https://git.cafe/gitcafe/zed/commit/f142568172972391df6ecae3a07f2e883013200e?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/c015baa6385202af1a965c6346af71426c7e377e?format=markdown)
