Ensure extra field values are correctly casted.

Closes #11.