bugfix
This commit is contained in:
parent
65e6ed36c5
commit
98004a8052
@ -114,6 +114,10 @@ where b.orgid = c.ownerid
|
|||||||
async def get_calluserid(self, appid, orgid=None):
|
async def get_calluserid(self, appid, orgid=None):
|
||||||
users = await self.get_apiusers(appid, orgid=orgid)
|
users = await self.get_apiusers(appid, orgid=orgid)
|
||||||
cnt = len(users)
|
cnt = len(users)
|
||||||
|
if cnt < 1:
|
||||||
|
e = Exception(f'get_calluserid():{appid=}, {orgid=} return None')
|
||||||
|
exception(f'{e}')
|
||||||
|
raise e
|
||||||
i = randint(0, cnt - 1)
|
i = randint(0, cnt - 1)
|
||||||
return users[i].userid
|
return users[i].userid
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user