fix bug when tag contais white spaces