'List organizations of which the user is a current or pending member.
:param str state: (option), state of the membership, i.e., active,
pending
:returns: iterator of :class:`Membership <github3.orgs.Membership>`'

@requires_auth
def organization_memberships(self, state=None, number=(-1), etag=None):

    params = None
    url = self._build_url(u'user', u'memberships', u'orgs')
    if ((state is not None) and (state.lower() in (u'active', u'pending'))):
        params = {u'state': state.lower()}
    return self._iter(int(number), url, Membership, params=params, etag=etag)
