fix(scheduled-posts): only throw account missing error if scheduledStatus is null
This fixes #623
This commit is contained in:
@@ -181,13 +181,13 @@ public abstract class StatusDisplayItem{
|
||||
Bundle args=new Bundle();
|
||||
args.putString("account", accountID);
|
||||
try{
|
||||
ScheduledStatus scheduledStatus=parentObject instanceof ScheduledStatus s ? s : null;
|
||||
|
||||
// Check if account is null. This should never happen, but it seems to do in latest versions of glitch-soc
|
||||
if (status.account == null || (status.reblog != null && status.reblog.account == null) || (status.quote != null) && status.quote.account == null) {
|
||||
if (scheduledStatus == null && status.account == null || (status.reblog != null && status.reblog.account == null) || (status.quote != null) && status.quote.account == null) {
|
||||
throw new Exception("status " + status.url + " has null account field");
|
||||
}
|
||||
|
||||
ScheduledStatus scheduledStatus=parentObject instanceof ScheduledStatus s ? s : null;
|
||||
|
||||
HeaderStatusDisplayItem header=null;
|
||||
boolean hideCounts=!AccountSessionManager.get(accountID).getLocalPreferences().showInteractionCounts;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user