Closed umair-ali-confiz closed 5 years ago
@umair-ali-confiz Please, be sure that your jalalFeed
wasn't deallocated after request. If it's not a problem, could you enable logs in the Client config and show the output?
Thanks, @buh for the quick response. Yes the issue with the jalalFeed object, it was deallocated after the call. I just change the scope of the object and issue resolved.
@umair-ali-confiz I'm having the same issue and am pretty new to swift. How did you resolve this issue?
Hi @ndyeager,
In the above example, immediately after the last use of jalalFeed
, it was automatically released, because it will no longer be used in the rest of the function, and no one knows about it outside the scope. At the same time, requests work asynchronously, so the request result will not be printed.
Usually, you have to declare jalalFeed
variable as an instance of some TimelineViewController
.
@buh Thank for your reply and the clarification.
Please wrap code blocks in backticks, like so:
What did you do?
I have set the client configuration with api key, appid and token. I have tested the token with rest API of Feed fetch and it is working over there.
What did you expect to happen?
I want to get feed using Stream-swift SDK. But it did not call completion block of jalalFeed.get.
What happened instead?
It should call the completion block of jalalFeed.get.
GetStream Environment
GetStream version: 1.0 Xcode version: 10.1 Swift version: 4.2 Platform(s) running GetStream: pod macOS version running Xcode: 10.14
Additional context
Add any other context about the problem here.