From 5da3fd6dc9f9930b11b5c96c0487ee232740f144 Mon Sep 17 00:00:00 2001 From: Sabrina Tardio <44158575+SabrinaTardio@users.noreply.github.com> Date: Tue, 15 Oct 2024 11:45:19 +0200 Subject: [PATCH] fix memory leak (#3396) Task/Issue URL: https://app.asana.com/0/1201048563534612/1208547799518177/f **Description**: Fix a memory leak (will add test later on) --- .../ContextualOnboarding/ContextualOnboardingStateMachine.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DuckDuckGo/Onboarding/ContextualOnboarding/ContextualOnboardingStateMachine.swift b/DuckDuckGo/Onboarding/ContextualOnboarding/ContextualOnboardingStateMachine.swift index 7c990e0e33..d400eac518 100644 --- a/DuckDuckGo/Onboarding/ContextualOnboarding/ContextualOnboardingStateMachine.swift +++ b/DuckDuckGo/Onboarding/ContextualOnboarding/ContextualOnboardingStateMachine.swift @@ -133,7 +133,7 @@ final class ContextualOnboardingStateMachine: ContextualOnboardingDialogTypeProv } } - private var lastVisitTab: Tab? + private weak var lastVisitTab: Tab? private var lastVisitSite: URL? private var notBlockedTrackerSeen: Bool = false