Skip to content

Commit 4a51ea3

Browse files
committed
fix bug
1 parent 3006173 commit 4a51ea3

File tree

1 file changed

+6
-2
lines changed
  • scripts/backup/ext/fb-auto-invite-share/popup/helpers

1 file changed

+6
-2
lines changed

scripts/backup/ext/fb-auto-invite-share/popup/helpers/facebook.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,7 @@ export async function sharePostToGroup({
325325
{
326326
link: {
327327
share_scrape_data: JSON.stringify({
328-
share_type: me.type === TargetType.Page ? 37 : 22,
328+
share_type: postOwner.type === TargetType.Group ? 37 : 22,
329329
share_params: [postId],
330330
}),
331331
},
@@ -372,9 +372,13 @@ export async function sharePostToGroup({
372372
__relay_internal__pv__StoriesArmadilloReplyEnabledrelayprovider: true,
373373
__relay_internal__pv__EventCometCardImage_prefetchEventImagerelayprovider: false,
374374
},
375-
doc_id: "8358507460852422",
375+
doc_id: "8288041211276925",
376376
});
377377
const json = JSON.parse(res?.split?.("\n")?.[0]);
378378
console.log(json);
379+
380+
const err = json?.errors?.[0]?.description;
381+
if (err) throw new Error(err);
382+
379383
return deepFindKeyInObject(json, "story")?.url;
380384
}

0 commit comments

Comments
 (0)