diff --git a/mesh_bot.py b/mesh_bot.py index 3d5552a..22fc78f 100755 --- a/mesh_bot.py +++ b/mesh_bot.py @@ -526,12 +526,10 @@ def handle_history(nodeid, deviceID, lheard=False): nodeName = get_name_from_number(cmdHistorySorted[i]['nodeID'], 'short', deviceID) if not any(d[0] == nodeName for d in buffer): buffer.append((nodeName, prettyTime)) - # truncate buffer list to 4 users if len(buffer) > 4: buffer = buffer[-4:] - - # format the buffer list into a string for display only return the last 4 users + # create the message from the buffer list for i in range(0, len(buffer)): msg += f"{buffer[i][0]} seen {buffer[i][1]} ago. "