more consistent use of loadFromJSON