fix syntax error because of replacing