Fixed bug with stringToKeyValue