Fix JSON deserialization