fixing bug when both input and append text are specified