Skip to content

Commit

Permalink
Fix polling timer not stopping
Browse files Browse the repository at this point in the history
Signed-off-by: Milen Pivchev <[email protected]>
  • Loading branch information
mpivchev committed Oct 22, 2024
1 parent d99c1e7 commit a7532a2
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
7 changes: 7 additions & 0 deletions iOSClient/Login/NCLoginPoll.swift
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,9 @@ struct NCLoginPoll: View {
loginManager.openLoginInBrowser()
}
}
.onDisappear {
loginManager.onDisappear()
}
.interactiveDismissDisabled()
}
}
Expand Down Expand Up @@ -146,6 +149,10 @@ private class LoginManager: ObservableObject {
timer.resume()
}

func onDisappear() {
timer?.cancel()
}

func openLoginInBrowser() {
UIApplication.shared.open(URL(string: loginFlowV2Login)!)
}
Expand Down
4 changes: 2 additions & 2 deletions iOSClient/Supporting Files/en.lproj/Localizable.strings
Original file line number Diff line number Diff line change
Expand Up @@ -969,8 +969,8 @@
"_creation_" = "Creation";
"_modified_" = "Modified";
"_group_folders_" = "Group folders";
"_play_from_files_" = "Play movie by Files";
"_play_from_url_" = "Play movie by URL";
"_play_from_files_" = "Play movie from a file";
"_play_from_url_" = "Play movie from URL";
"_valid_video_url_" = "Insert a valid URL";
"_deletion_progess_" = "Deletion in progress";
"_copying_progess_" = "Copying in progress";
Expand Down

0 comments on commit a7532a2

Please sign in to comment.