<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:

def _to_dict(objects):
    '''
    Potentially interprets a string as JSON for usage with mongo
    '''
    try:
        if isinstance(objects, six.string_types):
            objects = salt.utils.json.loads(objects)
    except ValueError as err:
        log.error("Could not parse objects: %s", err)
        raise err

    return objects