OSDN Git Service

投稿時取得の設定に関わらず投稿した発言を直ちにRecentタブに追加する
authorKimura Youichi <kim.upsilon@bucyou.net>
Sat, 28 May 2022 23:13:53 +0000 (08:13 +0900)
committerKimura Youichi <kim.upsilon@bucyou.net>
Thu, 7 Jul 2022 20:24:22 +0000 (05:24 +0900)
API v2 ではホームタイムラインが若干遅延しており、投稿直後に取得してもその発言が含まれていない場合があるため

OpenTween/Tween.cs

index 6292d5f..02bc23a 100644 (file)
@@ -1779,19 +1779,15 @@ namespace OpenTween
             this.SetMainWindowTitle();
 
             // TLに反映
-            if (this.settings.Common.PostAndGet)
-            {
-                await this.RefreshTabAsync<HomeTabModel>();
-            }
-            else
+            if (post != null)
             {
-                if (post != null)
-                {
-                    this.statuses.AddPost(post);
-                    this.statuses.DistributePosts();
-                }
+                this.statuses.AddPost(post);
+                this.statuses.DistributePosts();
                 this.RefreshTimeline();
             }
+
+            if (this.settings.Common.PostAndGet)
+                await this.RefreshTabAsync<HomeTabModel>();
         }
 
         private async Task RetweetAsync(IReadOnlyList<long> statusIds)