Skip to content

Commit

Permalink
Merge pull request #1002 from Portkey-Wallet/feature/dapp-safe
Browse files Browse the repository at this point in the history
Feature/dapp safe
  • Loading branch information
sunny-k123 authored Dec 4, 2024
2 parents 09f7966 + f2439ff commit 58b376b
Showing 1 changed file with 21 additions and 2 deletions.
23 changes: 21 additions & 2 deletions src/CAServer.Application.Contracts/Commons/WebsiteInfoHelper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,19 @@ public class WebsiteInfoHelper
{
public static bool WebsiteValild(WebsiteInfoDto info)
{
info.website = info.website.Replace("https://", "");

foreach (var pixiepoint in Pixiepoints)
{
if (info.website.EndsWith(pixiepoint.website))
{
return info.logo.Equals(pixiepoint.logo);
}
}

foreach (var website in WebsiteInfoes)
{
if (info.website.Replace("https://","").Equals(website.website))
if (info.website.Equals(website.website))
{
return info.logo.Equals(website.logo);
}
Expand All @@ -21,7 +31,6 @@ public static bool WebsiteValild(WebsiteInfoDto info)
{
return info.logo.Contains(info.website);
}

}

return true;
Expand All @@ -44,4 +53,14 @@ public static bool WebsiteValild(WebsiteInfoDto info)
new WebsiteInfoDto { website = "ewell.finance", logo = "https://icon.horse/icon/ewell.finance/50" },
new WebsiteInfoDto { website = "hamster.beangotown", logo = "https://icon.horse/icon/hamster.beangotown.com/50" },
};

private static List<WebsiteInfoDto> Pixiepoints = new List<WebsiteInfoDto>
{
new WebsiteInfoDto { website = "schrodingerai.com" ,logo = "https://icon.horse/icon/cat.schrodingerai.com/50"},
new WebsiteInfoDto { website = "ecoearn.cc",logo = "https://icon.horse/icon/app.ecoearn.cc/50"},
new WebsiteInfoDto { website = "awakenswap.xyz",logo = "https://icon.horse/icon/app.awaken.finance/50"},
new WebsiteInfoDto { website = "beangotown.xyz", logo = "https://icon.horse/icon/beangotown.com/50"},
new WebsiteInfoDto { website = "schrodingernft.ai",logo = "https://icon.horse/icon/cat.schrodingerai.com/50"},
new WebsiteInfoDto { website = "beangotown.com" ,logo = "https://icon.horse/icon/beangotown.com/50"},
};
}

0 comments on commit 58b376b

Please sign in to comment.