import typing


def get_device_organization(assignment: object = None, device_serial: str = None) -> typing.Any:
    """ get device owner (organization) information """

    organization = assignment.objects.filter(  # noqa
        device__serial=device_serial
    ).first()

    return organization
