(uid)
| 64 | } |
| 65 | |
| 66 | export async function setUserId(uid) { |
| 67 | if (!uid) { |
| 68 | uid = |
| 69 | ( |
| 70 | await chrome.cookies.get({ |
| 71 | url: "https://www.facebook.com", |
| 72 | name: "c_user", |
| 73 | }) |
| 74 | )?.value || new Date().getTime(); |
| 75 | } |
| 76 | CACHED.userID = uid; |
| 77 | await Storage.set("userId", uid); |
| 78 | } |
| 79 | |
| 80 | export async function getUserId() { |
| 81 | if (!CACHED.userID) { |