update string with a check method