From f544ec2f324257ab5b9bf3b392677715724b413d Mon Sep 17 00:00:00 2001 From: Naor Nagar Date: Tue, 31 Mar 2020 21:59:55 +0300 Subject: [PATCH] enable partial name search --- Piplapis/Data/Fields/Name.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Piplapis/Data/Fields/Name.cs b/Piplapis/Data/Fields/Name.cs index 3a6078d..50a00ee 100644 --- a/Piplapis/Data/Fields/Name.cs +++ b/Piplapis/Data/Fields/Name.cs @@ -89,9 +89,9 @@ public override bool IsSearchable { get { - return ((!String.IsNullOrEmpty(First) && _nonAbc.Replace(First, string.Empty).Length >= 2) && - (!String.IsNullOrEmpty(Last) && _nonAbc.Replace(Last, string.Empty).Length >= 2)) || - (!String.IsNullOrEmpty(Raw) && _nonAbc.Replace(Raw, string.Empty).Length >= 4); + return ((!String.IsNullOrEmpty(First) && _nonAbc.Replace(First, string.Empty).Length >= 1) && + (!String.IsNullOrEmpty(Last) && _nonAbc.Replace(Last, string.Empty).Length >= 1)) || + (!String.IsNullOrEmpty(Raw) && _nonAbc.Replace(Raw, string.Empty).Length >= 1); } } }