We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d2b4837 commit 65212d8Copy full SHA for 65212d8
src/VirtoCommerce.ContentModule.Data/Services/PublishingService.cs
@@ -75,8 +75,8 @@ private static void SetFileStatusByName(ContentFile file)
75
file.Name = RemoveDraftSuffix(file.Name);
76
file.RelativeUrl = RemoveDraftSuffix(file.RelativeUrl);
77
78
- string RemoveDraftSuffix(string name) => isDraft
79
- ? name.Substring(0, file.Name.Length - "-draft".Length)
+ string RemoveDraftSuffix(string name) => name.EndsWith("-draft")
+ ? name.Substring(0, name.Length - "-draft".Length)
80
: name;
81
}
82
0 commit comments