Open jaydipdeveloper opened 7 months ago
let userFeed = Client.shared.flatFeed(feedSlug: "user", userId: celebrity.memberId.uuidString.lowercased()) userFeed.callbackQueue = .main userFeed.subscribe(typeOf: Activity.self) { result in switch result { case .success(let activities): // Handle received activities print("Received activities: (activities)") case .failure(let error): // Handle subscription error print("Failed to subscribe: (error)") } }
still not working
I have a project in that we have page called community when all user can post so I need to subscribe to get updates
let userFeed = Client.shared.flatFeed(feedSlug: "community", userId: community_id_here)
userFeed.subscribe(typeOf: GetStreamActivity.self, subscription: { result in switch result { case .success(let activities): // Handle received activities print("Received activities: (activities)") case .failure(let error): // Handle subscription error print("Failed to subscribe: (error)") } })