'Make sure that a list of valid fields is being used.'

def validate(self, value):

    if (not isinstance(value, dict)):
        self.error('Only    dictionaries    may    be    used    in    a    DictField')
    if key_not_string(value):
        msg = 'Invalid    dictionary    key    -    documents    must    have    only    string    keys'
        self.error(msg)
    if key_has_dot_or_dollar(value):
        self.error('Invalid    dictionary    key    name    -    keys    may    not    contain    "."    or    "$"    characters')
    super(DictField, self).validate(value)
