Fixed 2 issues in the code

Scrutinizer pointed out a documentation error and a missing check of
the field type in the Enum adapter.