File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -6,12 +6,12 @@ namespace Schema.NET
66 public static class Constants
77 {
88 /// <summary>
9- /// The HTTPS URL for Schema.org
9+ /// The HTTPS URL for Schema.org, excluding trailing slash.
1010 /// </summary>
1111 public const string HttpsSchemaOrgUrl = "https://schema.org" ;
1212
1313 /// <summary>
14- /// The HTTPS URL for Schema.org
14+ /// The HTTP URL for Schema.org, excluding trailing slash.
1515 /// </summary>
1616 public const string HttpSchemaOrgUrl = "http://schema.org" ;
1717 }
Original file line number Diff line number Diff line change @@ -64,13 +64,13 @@ public static bool TryParseEnumFromSchemaUri(
6464 if ( value is not null && value . StartsWith ( Constants . HttpSchemaOrgUrl , StringComparison . OrdinalIgnoreCase ) )
6565 {
6666#pragma warning disable IDE0057 // Use range operator. Need to multi-target.
67- enumString = value . Substring ( Constants . HttpSchemaOrgUrl . Length ) ;
67+ enumString = value . Substring ( Constants . HttpSchemaOrgUrl . Length + 1 ) ;
6868#pragma warning restore IDE0057 // Use range operator. Need to multi-target.
6969 }
7070 else if ( value is not null && value . StartsWith ( Constants . HttpsSchemaOrgUrl , StringComparison . OrdinalIgnoreCase ) )
7171 {
7272#pragma warning disable IDE0057 // Use range operator. Need to multi-target.
73- enumString = value . Substring ( Constants . HttpsSchemaOrgUrl . Length ) ;
73+ enumString = value . Substring ( Constants . HttpsSchemaOrgUrl . Length + 1 ) ;
7474#pragma warning restore IDE0057 // Use range operator. Need to multi-target.
7575 }
7676 else
You can’t perform that action at this time.
0 commit comments