v7.3b2756 1. Visit a site 2. Open Share menu and select => Firefox => Add to Bookmarks => Add 3. Check Bookmarks panel Result: The site doesn't show up in the bookmarks list. Note: This issue is not reproducible on v7.2 (release)
The problem is as follows: insertBookmark(_:title:favicon:intoFolder:withTitle:) is an asynchronous function. It returns a Deferred. But that deferred gets lost in profile.shareItem() and is ignore. So the ShareTo app extension finishes and then closes the database connection too soon.
Created attachment 8860403 [details] [review] PR https://github.com/mozilla-mobile/firefox-ios/pull/2651 This patch makes `shareItem` return a `Success` (which is a `Deferred<Maybe<Void>>`) so that the caller can wait for asynchronous database operations to finish. Currently we just call `shareItem()` and then immediately `profile.shutdown()`, which is bad since we are still in the process of adding the bookmark. This patch makes it possible to properly wait.
Assignee: nobody → sarentz
Attachment #8860403 - Flags: review?(sleroux)
Status: NEW → RESOLVED
Last Resolved: 9 months ago
Resolution: --- → FIXED
Landed on both v7.x and master
Verifying as fixed in 7.3 (2772) release
Status: RESOLVED → VERIFIED
status-fxios-v7.3: affected → verified
Attachment #8860403 - Flags: review?(sleroux) → review+
You need to log in before you can comment on or make changes to this bug.