Skip to content

Commit 540a940

Browse files
authored
[Release] Hotfix 2.15.0 => 2.15.1 (patch) (#7839)
* chore: bump version to 2.15.1 * fix: filter out fuzzy matched results (#7840)
1 parent 6d77d6f commit 540a940

File tree

4 files changed

+12
-6
lines changed

4 files changed

+12
-6
lines changed

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"yarn": ">=999.0.0",
88
"npm": ">=999.0.0"
99
},
10-
"version": "2.15.0",
10+
"version": "2.15.1",
1111
"private": true,
1212
"license": "AGPL-3.0-or-later",
1313
"scripts": {

packages/mask/src/manifest.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "Mask Network",
3-
"version": "2.15.0",
3+
"version": "2.15.1",
44
"manifest_version": 2,
55
"permissions": ["storage", "downloads", "webNavigation", "activeTab"],
66
"optional_permissions": ["<all_urls>", "notifications", "clipboardRead"],

packages/plugins/EVM/src/state/IdentityService.ts

+4-2
Original file line numberDiff line numberDiff line change
@@ -42,12 +42,14 @@ function getAddress(text: string) {
4242

4343
function getNextIDPlatform() {
4444
if (getSiteType() === EnhanceableSite.Twitter) return NextIDPlatform.Twitter
45-
return NextIDPlatform.Twitter
45+
return
4646
}
4747

4848
async function getWalletAddressesFromNextID(userId?: string) {
4949
if (!userId) return EMPTY_LIST
50-
const bindings = await NextIDProof.queryAllExistedBindingsByPlatform(getNextIDPlatform(), userId)
50+
const platform = getNextIDPlatform()
51+
if (!platform) return EMPTY_LIST
52+
const bindings = await NextIDProof.queryAllExistedBindingsByPlatform(platform, userId)
5153
return bindings.flatMap((x) =>
5254
x.proofs.filter((y) => y.platform === NextIDPlatform.Ethereum && isValidAddress(y.identity)),
5355
)

packages/web3-providers/src/NextID/proof.ts

+6-2
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,12 @@ export class NextIDProofAPI implements NextIDBaseAPI.Proof {
117117
let page = 1
118118
do {
119119
const personaBindings = await this.queryExistedBindingByPlatform(platform, identity, page)
120-
if (personaBindings.length === 0) return nextIDPersonaBindings
120+
if (personaBindings.length === 0)
121+
return nextIDPersonaBindings.filter((x) =>
122+
x.proofs.some(
123+
(y) => y.platform === platform && y.identity.toLowerCase() === identity.toLowerCase(),
124+
),
125+
)
121126
nextIDPersonaBindings.push(...personaBindings)
122127
page += 1
123128
} while (page > 1)
@@ -129,7 +134,6 @@ export class NextIDProofAPI implements NextIDBaseAPI.Proof {
129134

130135
const url = getExistedBindingQueryURL(platform, identity, personaPublicKey)
131136
const result = await fetchJSON<BindingProof>(url, {}, enableCache)
132-
133137
return result.map(() => true).unwrapOr(false)
134138
}
135139

0 commit comments

Comments
 (0)