fix bug in parser