mirror of
				https://framagit.org/tom79/fedilab-tube
				synced 2025-06-05 21:09:11 +02:00 
			
		
		
		
	Some fixes
This commit is contained in:
		| @@ -189,7 +189,7 @@ public class PeertubeActivity extends AppCompatActivity { | |||||||
|         String userId = sharedpreferences.getString(Helper.PREF_KEY_ID, null); |         String userId = sharedpreferences.getString(Helper.PREF_KEY_ID, null); | ||||||
|         String instance = Helper.getLiveInstance(PeertubeActivity.this); |         String instance = Helper.getLiveInstance(PeertubeActivity.this); | ||||||
|         Account account = new AccountDAO(PeertubeActivity.this, db).getUniqAccount(userId, instance); |         Account account = new AccountDAO(PeertubeActivity.this, db).getUniqAccount(userId, instance); | ||||||
|         Helper.loadGiF(PeertubeActivity.this, account.getAvatar().getPath(), my_pp); |         Helper.loadGiF(PeertubeActivity.this, account.getAvatar()!=null?account.getAvatar().getPath():null, my_pp); | ||||||
|  |  | ||||||
|  |  | ||||||
|         if (Helper.isTablet(PeertubeActivity.this)) { |         if (Helper.isTablet(PeertubeActivity.this)) { | ||||||
|   | |||||||
| @@ -241,7 +241,7 @@ public class ShowChannelActivity extends AppCompatActivity { | |||||||
|  |  | ||||||
|  |  | ||||||
|         manageNotes(channel); |         manageNotes(channel); | ||||||
|         Helper.loadGiF(ShowChannelActivity.this, channel.getAvatar().getPath(), account_pp); |         Helper.loadGiF(ShowChannelActivity.this, channel.getAvatar()!=null?channel.getAvatar().getPath():null, account_pp); | ||||||
|         //Follow button |         //Follow button | ||||||
|         String target = channel.getAcct(); |         String target = channel.getAcct(); | ||||||
|  |  | ||||||
|   | |||||||
| @@ -203,7 +203,7 @@ public class DisplayVideosFragment extends Fragment implements AccountsHorizonta | |||||||
|                                 if (!flag_loading) { |                                 if (!flag_loading) { | ||||||
|                                     flag_loading = true; |                                     flag_loading = true; | ||||||
|                                     if (search_peertube == null) { //Not a Peertube search |                                     if (search_peertube == null) { //Not a Peertube search | ||||||
|                                         if( type != TimelineVM.TimelineType.USER_VIDEOS){ |                                         if( type == TimelineVM.TimelineType.USER_VIDEOS){ | ||||||
|                                             viewModelFeeds.getVideosInChannel(channelId, max_id).observe(DisplayVideosFragment.this.requireActivity(), apiResponse -> manageVIewVideos(apiResponse)); |                                             viewModelFeeds.getVideosInChannel(channelId, max_id).observe(DisplayVideosFragment.this.requireActivity(), apiResponse -> manageVIewVideos(apiResponse)); | ||||||
|                                         }else { |                                         }else { | ||||||
|                                             viewModelFeeds.getVideos(type, max_id).observe(DisplayVideosFragment.this.requireActivity(), apiResponse -> manageVIewVideos(apiResponse)); |                                             viewModelFeeds.getVideos(type, max_id).observe(DisplayVideosFragment.this.requireActivity(), apiResponse -> manageVIewVideos(apiResponse)); | ||||||
| @@ -226,7 +226,7 @@ public class DisplayVideosFragment extends Fragment implements AccountsHorizonta | |||||||
|                                 if (!flag_loading) { |                                 if (!flag_loading) { | ||||||
|                                     flag_loading = true; |                                     flag_loading = true; | ||||||
|                                     if (search_peertube == null) { //Not a Peertube search |                                     if (search_peertube == null) { //Not a Peertube search | ||||||
|                                         if( type != TimelineVM.TimelineType.USER_VIDEOS){ |                                         if( type == TimelineVM.TimelineType.USER_VIDEOS){ | ||||||
|                                             viewModelFeeds.getVideosInChannel(channelId, max_id).observe(DisplayVideosFragment.this.requireActivity(), apiResponse -> manageVIewVideos(apiResponse)); |                                             viewModelFeeds.getVideosInChannel(channelId, max_id).observe(DisplayVideosFragment.this.requireActivity(), apiResponse -> manageVIewVideos(apiResponse)); | ||||||
|                                         }else { |                                         }else { | ||||||
|                                             viewModelFeeds.getVideos(type, max_id).observe(DisplayVideosFragment.this.requireActivity(), apiResponse -> manageVIewVideos(apiResponse)); |                                             viewModelFeeds.getVideos(type, max_id).observe(DisplayVideosFragment.this.requireActivity(), apiResponse -> manageVIewVideos(apiResponse)); | ||||||
| @@ -401,7 +401,7 @@ public class DisplayVideosFragment extends Fragment implements AccountsHorizonta | |||||||
|         } |         } | ||||||
|         if (search_peertube == null) { //Not a Peertube search |         if (search_peertube == null) { //Not a Peertube search | ||||||
|  |  | ||||||
|             if( type != TimelineVM.TimelineType.USER_VIDEOS){ |             if( type == TimelineVM.TimelineType.USER_VIDEOS){ | ||||||
|                 viewModelFeeds.getVideosInChannel(channelId, "0").observe(this.requireActivity(), this::manageVIewVideos); |                 viewModelFeeds.getVideosInChannel(channelId, "0").observe(this.requireActivity(), this::manageVIewVideos); | ||||||
|             }else { |             }else { | ||||||
|                 viewModelFeeds.getVideos(type, "0").observe(this.requireActivity(), this::manageVIewVideos); |                 viewModelFeeds.getVideos(type, "0").observe(this.requireActivity(), this::manageVIewVideos); | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user