rcgit

/ karakeep

Commit 40fb4010

SHA 40fb401034b5a12a9346e0ab9d2505fb2fb92083
Author MohamedBassem <me at mbassem dot com>
Author Date 2025-03-16 12:47 +0000
Committer MohamedBassem <me at mbassem dot com>
Commit Date 2025-03-16 12:48 +0000
Parent(s) c388fb2caecf (diff)
Tree 0f6215a9dae0

patch snapshot

fix(mobile): Fix shared links getting stored as text. #956
File + - Graph
M apps/mobile/app.json +3 -3
M apps/mobile/app/sharing.tsx +3 -1
2 file(s) changed, 6 insertions(+), 4 deletions(-)

apps/mobile/app.json

diff --git a/apps/mobile/app.json b/apps/mobile/app.json
index ffc7e6af..c1162dd6 100644
--- a/apps/mobile/app.json
+++ b/apps/mobile/app.json
@@ -3,7 +3,7 @@
     "name": "Hoarder App",
     "slug": "hoarder",
     "scheme": "hoarder",
-    "version": "1.6.8",
+    "version": "1.6.9",
     "orientation": "portrait",
     "icon": "./assets/icon.png",
     "userInterfaceStyle": "automatic",
@@ -29,7 +29,7 @@
           "NSAllowsArbitraryLoads": true
         }
       },
-      "buildNumber": "21"
+      "buildNumber": "22"
     },
     "android": {
       "adaptiveIcon": {
@@ -47,7 +47,7 @@
         }
       },
       "package": "app.hoarder.hoardermobile",
-      "versionCode": 21
+      "versionCode": 22
     },
     "plugins": [
       "./plugins/trust-local-certs.js",

apps/mobile/app/sharing.tsx

diff --git a/apps/mobile/app/sharing.tsx b/apps/mobile/app/sharing.tsx
index e2e1823b..55c2da9d 100644
--- a/apps/mobile/app/sharing.tsx
+++ b/apps/mobile/app/sharing.tsx
@@ -42,7 +42,9 @@ function SaveBookmark({ setMode }: { setMode: (mode: Mode) => void }) {
     if (isLoading) {
       return;
     }
-    if (!isPending && shareIntent?.text) {
+    if (!isPending && shareIntent.webUrl) {
+      mutate({ type: BookmarkTypes.LINK, url: shareIntent.webUrl });
+    } else if (!isPending && shareIntent?.text) {
       const val = z.string().url();
       if (val.safeParse(shareIntent.text).success) {
         // This is a URL, else treated as text