magicrew-auth 0.3.36 → 0.3.37
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +1703 -1695
- package/package.json +1 -1
- package/src/hooks/methods.mjs +2 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "magicrew-auth",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.37",
|
|
4
4
|
"description": "超级麦吉 / MagiCrew for magpie and OpenCode — one package, two providers: letsmagic.cn (国内) and magicrew.ai (international). Password or web-JWT sign-in, the account's own live model list, points balance, newcomer rewards, invite codes.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./index.mjs",
|
package/src/hooks/methods.mjs
CHANGED
|
@@ -383,8 +383,9 @@ function inviteEntries(c) {
|
|
|
383
383
|
const author = authorInvite(c.id)
|
|
384
384
|
if (author) out.push({ n: 0, label: "我的(作者 MYCF711)", code: author, org: "", accountId: "MYCF711" })
|
|
385
385
|
const codes = readAccountCodes(c.id)
|
|
386
|
+
const live = liveOrgs(c.id)
|
|
386
387
|
const rows = Object.entries(codes)
|
|
387
|
-
.filter(([, v]) => v?.code && v.code !== author)
|
|
388
|
+
.filter(([org, v]) => v?.code && v.code !== author && (!live || live.size === 0 || live.has(org)))
|
|
388
389
|
.sort((a, b) => String(a[1].accountId || a[0]).localeCompare(String(b[1].accountId || b[0]), "zh"))
|
|
389
390
|
for (const [org, v] of rows) {
|
|
390
391
|
out.push({ n: out.length, label: String(v.accountId || org), code: v.code, org, accountId: String(v.accountId || org) })
|