diff --git a/samples/react-search-refiners/src/services/TemplateService/BaseTemplateService.ts b/samples/react-search-refiners/src/services/TemplateService/BaseTemplateService.ts index 25ea9942a..6eeed62b7 100644 --- a/samples/react-search-refiners/src/services/TemplateService/BaseTemplateService.ts +++ b/samples/react-search-refiners/src/services/TemplateService/BaseTemplateService.ts @@ -176,7 +176,7 @@ abstract class BaseTemplateService { // Return the URL or Title part of a URL automatic managed property //

{{getDate MyLinkOWSURLH "Title"}}

Handlebars.registerHelper("getUrlField", (urlField: string, value: "URL" | "Title") => { - let separatorPos = urlField.lastIndexOf(","); + let separatorPos = urlField.indexOf(","); if (value === "URL") { return urlField.substr(0, separatorPos); }