mirror of
https://github.com/BOSWatch/BW3-Core.git
synced 2025-12-06 07:12:04 +01:00
fix some pep8 errors
This commit is contained in:
parent
e359a0c646
commit
40d7a33a02
|
|
@ -45,13 +45,13 @@ class BoswatchPlugin(PluginBase):
|
||||||
if bwPacket.get("lat") is not None and bwPacket.get("lon") is not None:
|
if bwPacket.get("lat") is not None and bwPacket.get("lon") is not None:
|
||||||
logging.debug("Found coordinates in packet")
|
logging.debug("Found coordinates in packet")
|
||||||
(lat, lon) = (bwPacket.get("lat"), bwPacket.get("lon"))
|
(lat, lon) = (bwPacket.get("lat"), bwPacket.get("lon"))
|
||||||
|
|
||||||
for chatId in self.config.get("chatIds", default=[]):
|
for chatId in self.config.get("chatIds", default=[]):
|
||||||
try:
|
try:
|
||||||
# Send Message via Telegram
|
# Send Message via Telegram
|
||||||
logging.info("Sending message to " + chatId)
|
logging.info("Sending message to " + chatId)
|
||||||
self.bot.send_message(chat_id=chatId, text=msg)
|
self.bot.send_message(chat_id=chatId, text=msg)
|
||||||
|
|
||||||
# Send Location via Telegram if lat and lon are defined
|
# Send Location via Telegram if lat and lon are defined
|
||||||
if lat is not None and lon is not None:
|
if lat is not None and lon is not None:
|
||||||
logging.info("Sending location to " + chatId)
|
logging.info("Sending location to " + chatId)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue