def find_device(device=None):

    data = [{'uid': '/zport/dmd/Devices', 'params': {}, 'limit': None}]
    all_devices = _router_request('DeviceRouter', 'getDevices', data=data)
    for dev in all_devices['devices']:
        if dev['name'] == device:
            # We need to save the has for later operations
            dev['hash'] = all_devices['hash']
            log.info('Found device %s in Zenoss', device)
            return dev

    log.info('Unable to find device %s in Zenoss', device)
    return None
Construct an element of `self` domain from `a`.
dataset/ETHPy150Open saltstack/salt/salt/modules/zenoss.py/find_device--crossover with--dataset/ETHPy150Open sympy/sympy/sympy/polys/domains/quotientring.py/QuotientRing.new