change string type to object