Don't modify passed in properties hash (Fixes #420).

The properties hash is being modified when calling `createRecord`, reported in #420, this fixes the issue.