Araeynn commited on
Commit
ad680a1
·
verified ·
1 Parent(s): 36dce1f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -43,6 +43,7 @@ launch_time = datetime.datetime.utcnow()
43
  ph = st.empty()
44
 
45
  async def syncMessages():
 
46
  with ph.container():
47
  dirs = st.tabs(os.listdir("data"))
48
  i = -1
@@ -59,7 +60,7 @@ async def syncMessages():
59
  for item in o:
60
  o = o.split(": ", 1)
61
  st.markdown(f":blue[{o[0]}]: {o[1]}")
62
-
63
 
64
  @client.event
65
  async def on_ready():
@@ -73,6 +74,7 @@ async def presence():
73
  minutes, seconds = divmod(remainder, 60)
74
  days, hours = divmod(hours, 24)
75
  print(f"Online Time: {days:02d}d | {hours:02d}h | {minutes:02d}m | {seconds:02d}s")
 
76
  await client.change_presence(
77
  status=discord.Status.dnd,
78
  activity=discord.Activity(
@@ -84,7 +86,6 @@ async def presence():
84
  state=f"Running for {days:02d}d | {hours:02d}h | {minutes:02d}m",
85
  ),
86
  )
87
- await syncMessages()
88
 
89
 
90
  @client.event
 
43
  ph = st.empty()
44
 
45
  async def syncMessages():
46
+ print("Syncing Messages.")
47
  with ph.container():
48
  dirs = st.tabs(os.listdir("data"))
49
  i = -1
 
60
  for item in o:
61
  o = o.split(": ", 1)
62
  st.markdown(f":blue[{o[0]}]: {o[1]}")
63
+ print(o)
64
 
65
  @client.event
66
  async def on_ready():
 
74
  minutes, seconds = divmod(remainder, 60)
75
  days, hours = divmod(hours, 24)
76
  print(f"Online Time: {days:02d}d | {hours:02d}h | {minutes:02d}m | {seconds:02d}s")
77
+ await syncMessages()
78
  await client.change_presence(
79
  status=discord.Status.dnd,
80
  activity=discord.Activity(
 
86
  state=f"Running for {days:02d}d | {hours:02d}h | {minutes:02d}m",
87
  ),
88
  )
 
89
 
90
 
91
  @client.event