mirror of
https://github.com/Docile-Alligator/Infinity-For-Reddit.git
synced 2026-08-18 02:51:58 +00:00
Fix app crashes when RedditError is not available when loading posts fails in PostPagingSource.
This commit is contained in:
@ -273,7 +273,7 @@ public class PostPagingSource extends ListenableFuturePagingSource<String, Post>
|
||||
RedditError redditError = new Gson().fromJson(errorBody.string(), RedditError.class);
|
||||
return new LoadResult.Error<>(new PostPagingSourceError(response.code(), redditError.getReason()));
|
||||
}
|
||||
} catch (IOException e) {
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
return new LoadResult.Error<>(new PostPagingSourceError(response.code(), null));
|
||||
|
||||
Reference in New Issue
Block a user