Roachbones / discordless

Record Discord traffic via mitmproxy and export chatlogs to JSON or HTML.
GNU General Public License v3.0
71 stars 5 forks source link

fix add_observation - add missing self. #2

Closed slatinsky closed 1 year ago

slatinsky commented 1 year ago

fix missing self.

Fixes this stack traceback:

>py dcejson_exporter.py

 🧿 Initializing export 🧿

Analyzing REST traffic.
Analyzing websocket traffic.
Traceback (most recent call last):
  File "C:\_\programming\discordless\dcejson_exporter.py", line 437, in <module>
    observe_dmo(seen_timestamp, None, event_name, int(event["channel_id"]), int(event["id"]))
  File "C:\_\programming\discordless\dcejson_exporter.py", line 375, in observe_dmo
    channel_messages[channel_id][message_id].add_observation(observation)
  File "C:\_\programming\discordless\dcejson_exporter.py", line 295, in add_observation
    observations[-1] = min(observation, observations[-1])
NameError: name 'observations' is not defined. Did you mean: 'observation'?
Roachbones commented 1 year ago

Thanks! Guess I never ran into that