Fix #58: don't calc when input.length <= 2

This commit is contained in:
Yeechan Lu 2014-03-19 22:32:41 +08:00
parent bc85b3599e
commit c068366ae2

View File

@ -34,7 +34,7 @@ namespace Wox.Plugin.System
protected override List<Result> QueryInternal(Query query)
{
if (string.IsNullOrEmpty(query.RawQuery)
|| query.RawQuery.Length < 2 // don't affect when user only input "e" or "i" keyword
|| query.RawQuery.Length <= 2 // don't affect when user only input "e" or "i" keyword
|| !regValidExpressChar.IsMatch(query.RawQuery)
|| !IsBracketComplete(query.RawQuery)) return new List<Result>();