Skip to content

Extension - Update for patch chain #4382

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: subwallet-dev
Choose a base branch
from

Conversation

PDTnhah
Copy link

@PDTnhah PDTnhah commented May 20, 2025

No description provided.

@PDTnhah PDTnhah requested a review from nampc1 May 20, 2025 08:38
@PDTnhah PDTnhah self-assigned this May 20, 2025
@PDTnhah PDTnhah requested a review from S2kael May 20, 2025 08:38
@PDTnhah PDTnhah linked an issue May 20, 2025 that may be closed by this pull request
5 tasks
@saltict
Copy link

saltict commented May 20, 2025

🚀 Deployed on https://pr-4382--sw-web-runner.netlify.app

@saltict saltict temporarily deployed to pull request May 20, 2025 08:50 Inactive

if (duplicatedDefaultSlug.length > 0) {
deprecatedChainMap[storedSlug] = duplicatedDefaultSlug;
deprecatedChains.push(storedSlug);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't remove deprecated chains in the result?

if (!duplicated && !deprecated) {
mergedAssetRegistry[storedAssetInfo.slug] = storedAssetInfo;
} else {
deprecatedAssets.push(storedAssetInfo.slug);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't remove deprecated assets in the result?


// Update custom assets of merged custom chains
Object.values(storedAssetRegistry).forEach((storedAsset) => {
if (_isCustomAsset(storedAsset.slug) && Object.keys(deprecatedChainMap).includes(storedAsset.originChain)) {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only custom asset?

const duplicatedDefaultSlug = this.checkExistedPredefinedChain(latestChainInfo, storedChainInfo.substrateInfo?.genesisHash, storedChainInfo.evmInfo?.evmChainId);

if (duplicatedDefaultSlug.length > 0) {
deprecatedChainMap[storedSlug] = duplicatedDefaultSlug;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In case duplicate, have to migrate setting

if (!duplicated && !deprecated) {
mergedAssetRegistry[storedAssetInfo.slug] = storedAssetInfo;
} else {
deprecatedAssets.push(storedAssetInfo.slug);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Have to migrate setting

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Extension - Update for patch chain
3 participants