|
|
@ -516,34 +516,26 @@ public class RetrofitPeertubeAPI {
|
|
|
|
Call<VideoData> videoCall = null;
|
|
|
|
Call<VideoData> videoCall = null;
|
|
|
|
ArrayList<String> filter = selection != null ? new ArrayList<>(selection) : null;
|
|
|
|
ArrayList<String> filter = selection != null ? new ArrayList<>(selection) : null;
|
|
|
|
switch (timelineType) {
|
|
|
|
switch (timelineType) {
|
|
|
|
case MY_VIDEOS:
|
|
|
|
case MY_VIDEOS -> videoCall = peertubeService.getMyVideos(getToken(), max_id, count);
|
|
|
|
videoCall = peertubeService.getMyVideos(getToken(), max_id, count);
|
|
|
|
case ACCOUNT_VIDEOS ->
|
|
|
|
break;
|
|
|
|
videoCall = peertubeService.getVideosForAccount(forAccount, max_id, count, showNSFWVideos);
|
|
|
|
case ACCOUNT_VIDEOS:
|
|
|
|
case SUBSCRIBTIONS -> {
|
|
|
|
videoCall = peertubeService.getVideosForAccount(forAccount, max_id, count, showNSFWVideos);
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
case SUBSCRIBTIONS:
|
|
|
|
|
|
|
|
if (forAccount == null) {
|
|
|
|
if (forAccount == null) {
|
|
|
|
videoCall = peertubeService.getSubscriptionVideos(getToken(), max_id, count, filter);
|
|
|
|
videoCall = peertubeService.getSubscriptionVideos(getToken(), max_id, count, filter);
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
videoCall = peertubeService.getChannelVideos(forAccount, max_id, count, showNSFWVideos);
|
|
|
|
videoCall = peertubeService.getChannelVideos(forAccount, max_id, count, showNSFWVideos);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
case MOST_LIKED:
|
|
|
|
case MOST_LIKED ->
|
|
|
|
videoCall = peertubeService.getMostLikedVideos(getToken(), max_id, count, showNSFWVideos, filter);
|
|
|
|
videoCall = peertubeService.getMostLikedVideos(getToken(), max_id, count, showNSFWVideos, filter);
|
|
|
|
break;
|
|
|
|
case LOCAL ->
|
|
|
|
case LOCAL:
|
|
|
|
videoCall = peertubeService.getLocalVideos(getToken(), max_id, count, showNSFWVideos, filter);
|
|
|
|
videoCall = peertubeService.getLocalVideos(getToken(), max_id, count, showNSFWVideos, filter);
|
|
|
|
case TRENDING ->
|
|
|
|
break;
|
|
|
|
videoCall = peertubeService.getTrendingVideos(getToken(), max_id, count, showNSFWVideos, filter);
|
|
|
|
case TRENDING:
|
|
|
|
case HISTORY ->
|
|
|
|
videoCall = peertubeService.getTrendingVideos(getToken(), max_id, count, showNSFWVideos, filter);
|
|
|
|
videoCall = peertubeService.getHistory(getToken(), max_id, count, showNSFWVideos, null, null);
|
|
|
|
break;
|
|
|
|
case RECENT ->
|
|
|
|
case HISTORY:
|
|
|
|
videoCall = peertubeService.getRecentlyAddedVideos(getToken(), max_id, count, showNSFWVideos, filter);
|
|
|
|
videoCall = peertubeService.getHistory(getToken(), max_id, count, showNSFWVideos, null, null);
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
case RECENT:
|
|
|
|
|
|
|
|
videoCall = peertubeService.getRecentlyAddedVideos(getToken(), max_id, count, showNSFWVideos, filter);
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (videoCall != null) {
|
|
|
|
if (videoCall != null) {
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|