Skip to content
This repository has been archived by the owner on Jun 13, 2023. It is now read-only.

Commit

Permalink
Merge pull request #46 from VirtoCommerce/VDS-326
Browse files Browse the repository at this point in the history
VDS-326: Change the VirtoCommerce link in the footer of current Electronics theme demo to point at B2B
  • Loading branch information
pushnitsa authored Dec 2, 2020
2 parents 3a79425 + 1bd781a commit 2252c7b
Showing 1 changed file with 3 additions and 14 deletions.
17 changes: 3 additions & 14 deletions VirtoCommerce.LiquidThemeEngine/Filters/CommonFilters.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,17 +24,7 @@ namespace VirtoCommerce.LiquidThemeEngine.Filters
public static partial class CommonFilters
{
private static readonly string[] _poweredLinks = {
"<a href=\"http://virtocommerce.com\" rel=\"nofollow\" target=\"_blank\">.NET ecommerce platform</a> by Virto",
"<a href=\"http://virtocommerce.com/shopping-cart\" rel=\"nofollow\" target=\"_blank\">Shopping Cart</a> by Virto",
"<a href=\"http://virtocommerce.com/shopping-cart\" rel=\"nofollow\" target=\"_blank\">.NET Shopping Cart</a> by Virto",
"<a href=\"http://virtocommerce.com/shopping-cart\" rel=\"nofollow\" target=\"_blank\">ASP.NET Shopping Cart</a> by Virto",
"<a href=\"http://virtocommerce.com\" rel=\"nofollow\" target=\"_blank\">.NET ecommerce</a> by Virto",
"<a href=\"http://virtocommerce.com\" rel=\"nofollow\" target=\"_blank\">.NET ecommerce framework</a> by Virto",
"<a href=\"http://virtocommerce.com\" rel=\"nofollow\" target=\"_blank\">ASP.NET ecommerce</a> by Virto Commerce",
"<a href=\"http://virtocommerce.com\" rel=\"nofollow\" target=\"_blank\">ASP.NET ecommerce platform</a> by Virto",
"<a href=\"http://virtocommerce.com\" rel=\"nofollow\" target=\"_blank\">ASP.NET ecommerce framework</a> by Virto",
"<a href=\"http://virtocommerce.com\" rel=\"nofollow\" target=\"_blank\">Enterprise ecommerce</a> by Virto",
"<a href=\"http://virtocommerce.com\" rel=\"nofollow\" target=\"_blank\">Enterprise ecommerce platform</a> by Virto",
"<a href=\"https://virtocommerce.com/b2b-ecommerce-platform\" target=\"_blank\">B2B ecommerce platform</a> by Virto Commerce",
};

private static readonly JsonSerializerSettings _jsonSerializerSettings = new JsonSerializerSettings
Expand Down Expand Up @@ -67,10 +57,9 @@ public static object ParseJson(string input)
return result;
}

public static string PoweredBy(string signature)
public static string PoweredBy()
{
var hashCode = (uint)signature.GetHashCode();
return _poweredLinks[hashCode % _poweredLinks.Length];
return _poweredLinks.FirstOrDefault();
}

public static string Render(TemplateContext context, string input)
Expand Down

0 comments on commit 2252c7b

Please sign in to comment.