From 8f94eafcb3c08955bd410c64f641ec08e1e66871 Mon Sep 17 00:00:00 2001 From: Daniel Bernal Date: Wed, 30 Oct 2024 00:19:40 +0100 Subject: [PATCH] Blind attempt to fix Omnibar-related crash (#3500) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Task/Issue URL: https://app.asana.com/0/414709148257752/1208653357224780/f **Description**: Attempt to fix crash: Sentry: https://errors.duckduckgo.com/organizations/ddg/issues/169611/?project=8&query=is%3Aunresolved+firstSeen%3A-15d&referrer=issue-stream&sort=freq&statsPeriod=14d&stream_index=0 --- DuckDuckGo/OmniBar.swift | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/DuckDuckGo/OmniBar.swift b/DuckDuckGo/OmniBar.swift index d12d00d8e9..61850c6f2c 100644 --- a/DuckDuckGo/OmniBar.swift +++ b/DuckDuckGo/OmniBar.swift @@ -384,8 +384,8 @@ class OmniBar: UIView { searchStackContainer.setCustomSpacing(13, after: voiceSearchButton) } - UIView.animate(withDuration: 0.0) { - self.layoutIfNeeded() + UIView.animate(withDuration: 0.0) { [weak self] in + self?.layoutIfNeeded() } }