From 781c37fbae25ca774c7723045efff43e4a7f86d7 Mon Sep 17 00:00:00 2001 From: Shadowfacts Date: Mon, 28 Mar 2022 22:23:33 -0400 Subject: [PATCH] Fix crash when refreshing My Profile Closes #140 --- .../Screens/Profile/ProfileStatusesViewController.swift | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Tusker/Screens/Profile/ProfileStatusesViewController.swift b/Tusker/Screens/Profile/ProfileStatusesViewController.swift index 85aa1681..ce55fd16 100644 --- a/Tusker/Screens/Profile/ProfileStatusesViewController.swift +++ b/Tusker/Screens/Profile/ProfileStatusesViewController.swift @@ -240,6 +240,14 @@ extension ProfileStatusesViewController { struct Item: Hashable { let id: String let state: StatusState + + static func ==(lhs: Item, rhs: Item) -> Bool { + return lhs.id == rhs.id + } + + func hash(into hasher: inout Hasher) { + hasher.combine(id) + } } }