Fixed a bug that trailing '+' pattern (e.g. 'bg+') is not working adequately.