mirror of
https://github.com/tuskyapp/Tusky
synced 2024-12-25 00:11:15 +01:00
fix crash because of null visibility (#1478)
* fix crash because of null visibility * fix crash because of null visibility
This commit is contained in:
parent
9b8b036974
commit
c04c51ce41
@ -729,6 +729,10 @@ public abstract class StatusBaseViewHolder extends RecyclerView.ViewHolder {
|
||||
|
||||
private static CharSequence getVisibilityDescription(Context context, Status.Visibility visibility) {
|
||||
|
||||
if(visibility == null) {
|
||||
return "";
|
||||
}
|
||||
|
||||
int resource;
|
||||
switch (visibility) {
|
||||
case PUBLIC:
|
||||
|
@ -221,6 +221,10 @@ class StatusDetailedViewHolder extends StatusBaseViewHolder {
|
||||
|
||||
private void setStatusVisibility(Status.Visibility visibility) {
|
||||
|
||||
if(visibility == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
int visibilityIcon;
|
||||
switch (visibility) {
|
||||
case PUBLIC:
|
||||
|
Loading…
Reference in New Issue
Block a user