Search bar searches deleted query after switching to another tab

Description of the issue: typing something in the brave search bar, switching away to another tab, then coming back to type something different in it results in brave searching for the old query instead of the new one.

How can this issue be reproduced?

  1. set the default search engine to Brave
  2. open a new tab
  3. type something in the search bar, e.g. “abc”
  4. switch to a different tab
  5. come back to the tab opened in step 2.
  6. delete the text in the search bar and type something different, e.g. “123”
  7. press enter to search
  8. Brave search will search for “abc” instead of “123”

Expected result: Brave search should search for “123”

Brave Version: 1.67.123