mirror of
https://github.com/SpudGunMan/meshing-around.git
synced 2026-08-08 09:53:02 +02:00
Update mesh_bot.py
This commit is contained in:
+3
-2
@@ -543,8 +543,9 @@ def handle_history(nodeid, deviceID, lheard=False):
|
||||
buffer = buffer[-4:]
|
||||
# create the message from the buffer list
|
||||
for i in range(0, len(buffer)):
|
||||
msg += f"{buffer[i][0]}: {buffer[i][1]} :{buffer[i][2]} ago.\n"
|
||||
|
||||
msg += f"{buffer[i][0]}: {buffer[i][1]} :{buffer[i][2]} ago."
|
||||
if i < len(buffer) - 1:
|
||||
msg += f"\n"
|
||||
else:
|
||||
# sort the cmdHistory list by time, return the username and time into a new list which used for display
|
||||
cmdHistorySorted = sorted(cmdHistory, key=lambda k: k['time'], reverse=True)
|
||||
|
||||
Reference in New Issue
Block a user