mirror of
https://github.com/jlu5/PyLink.git
synced 2024-11-01 01:09:22 +01:00
PyLinkNetworkCore: fix extraneous warnings in get_service_bot
This commit is contained in:
parent
8170e777e8
commit
bc48709595
@ -471,7 +471,7 @@ class PyLinkNetworkCore(structures.DeprecatedAttributesObject, structures.CamelC
|
|||||||
# Look for the "service" attribute in the User object,sname = userobj.service
|
# Look for the "service" attribute in the User object,sname = userobj.service
|
||||||
# Warn if the service name we fetched isn't a registered service.
|
# Warn if the service name we fetched isn't a registered service.
|
||||||
sname = userobj.service
|
sname = userobj.service
|
||||||
if sname not in world.services.keys():
|
if sname is not None and sname not in world.services.keys():
|
||||||
log.warning("(%s) User %s / %s had a service bot record to a service that doesn't "
|
log.warning("(%s) User %s / %s had a service bot record to a service that doesn't "
|
||||||
"exist (%s)!", self.name, uid, userobj.nick, sname)
|
"exist (%s)!", self.name, uid, userobj.nick, sname)
|
||||||
return world.services.get(sname)
|
return world.services.get(sname)
|
||||||
|
Loading…
Reference in New Issue
Block a user