fix regression bug in completion