Resolve an issue where ttyverse would show direct messages per startup when connecting to Pleroma instances.
This commit is contained in:
+4
-3
@@ -6608,8 +6608,8 @@ sub dmrefresh {
|
||||
next;
|
||||
}
|
||||
|
||||
# For background refresh (interactive=0), use unread flag detection with local tracking fallback
|
||||
if (!$interactive && !$sent_dm) {
|
||||
# For background refresh (interactive=0) OR first-time initialization, use unread flag detection with local tracking fallback
|
||||
if ((!$interactive && !$sent_dm) || $dm_first_time) {
|
||||
my $is_unread = $j->{'unread'} || 0;
|
||||
my $conversation_id = $j->{'id'};
|
||||
my $last_status_id = $j->{'last_status'}->{'id'} || $j->{'last_status'}->{'id_str'};
|
||||
@@ -6624,7 +6624,8 @@ sub dmrefresh {
|
||||
}
|
||||
|
||||
# For servers that support unread flag, also check that
|
||||
if (!$is_unread && !$dm_seen_status{$tracking_key}) {
|
||||
# But skip this check during first-time initialization to ensure DMs are shown
|
||||
if (!$is_unread && !$dm_seen_status{$tracking_key} && !$dm_first_time) {
|
||||
print $stdout "-- DEBUG: Skipping DM #$i - already read (unread=false)\n" if ($verbose);
|
||||
next;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user