added fix for logic issue of string comparison