From 32c13fddc5622a71acf091525063605fa8d58df0 Mon Sep 17 00:00:00 2001 From: Carlos Garcia Date: Wed, 15 Sep 2021 16:28:33 +0200 Subject: [PATCH 1/4] Update synced media references after saving post --- WordPress/Classes/Services/PostCoordinator.swift | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/WordPress/Classes/Services/PostCoordinator.swift b/WordPress/Classes/Services/PostCoordinator.swift index 3ea03bd9cb58..67b3698eaee2 100644 --- a/WordPress/Classes/Services/PostCoordinator.swift +++ b/WordPress/Classes/Services/PostCoordinator.swift @@ -137,6 +137,13 @@ class PostCoordinator: NSObject { return } + // Ensure that all synced media references are up to date + post.media.forEach { media in + if media.remoteStatus == .sync { + self.updateReferences(to: media, in: post) + } + } + let uuid = observeMedia(for: post, completion: completion) trackObserver(receipt: uuid, for: post) From 6c47f96d1f8a9d89a68288cb277357734583ba79 Mon Sep 17 00:00:00 2001 From: Carlos Garcia Date: Wed, 15 Sep 2021 16:39:05 +0200 Subject: [PATCH 2/4] Correct lint issues in PostCoordinator --- WordPress/Classes/Services/PostCoordinator.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/WordPress/Classes/Services/PostCoordinator.swift b/WordPress/Classes/Services/PostCoordinator.swift index 67b3698eaee2..494a38d85783 100644 --- a/WordPress/Classes/Services/PostCoordinator.swift +++ b/WordPress/Classes/Services/PostCoordinator.swift @@ -143,7 +143,7 @@ class PostCoordinator: NSObject { self.updateReferences(to: media, in: post) } } - + let uuid = observeMedia(for: post, completion: completion) trackObserver(receipt: uuid, for: post) From 3caa8bbd4b80f30ce1366d39eb954daf01197ef1 Mon Sep 17 00:00:00 2001 From: Carlos Garcia Date: Wed, 15 Sep 2021 17:25:17 +0200 Subject: [PATCH 3/4] Update release notes --- RELEASE-NOTES.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/RELEASE-NOTES.txt b/RELEASE-NOTES.txt index eaffac3d5145..d62c5ca859b4 100644 --- a/RELEASE-NOTES.txt +++ b/RELEASE-NOTES.txt @@ -2,6 +2,7 @@ ----- * [*] Fixed a bug on Reader that prevented Saved posts to be removed * [*] Share Extension: Allow creation of Pages in addition to Posts. [#16084] +* [*] Fixed an issue where images point to local URLs in the editor when saving a post with ongoing uploads. [#17157] 18.2 ----- From 6c506c82fd2c0fdd018c8481e58da89f4fa80577 Mon Sep 17 00:00:00 2001 From: Carlos Garcia Date: Mon, 20 Sep 2021 15:22:22 +0200 Subject: [PATCH 4/4] Update release notes --- RELEASE-NOTES.txt | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/RELEASE-NOTES.txt b/RELEASE-NOTES.txt index c452dd826a55..c63110e38867 100644 --- a/RELEASE-NOTES.txt +++ b/RELEASE-NOTES.txt @@ -1,12 +1,11 @@ 18.4 ----- - +* [*] Fixed an issue where images point to local URLs in the editor when saving a post with ongoing uploads. [#17157] 18.3 ----- * [*] Fixed a bug on Reader that prevented Saved posts to be removed * [*] Share Extension: Allow creation of Pages in addition to Posts. [#16084] -* [*] Fixed an issue where images point to local URLs in the editor when saving a post with ongoing uploads. [#17157] * [*] Updated the wording for the "Posts" and "Pages" entries in My Site screen [https://github.com/wordpress-mobile/WordPress-iOS/pull/17156] * [*] Fixed an issue that caused `Follow conversation by email` to not appear on some post's comments. [#17159] * [**] Block editor: Embed block: Enable WordPress embed preview [https://github.com/wordpress-mobile/gutenberg-mobile/pull/3853]