Skip to content

Commit

Permalink
fix: Change encoding codec
Browse files Browse the repository at this point in the history
  • Loading branch information
cocoquiet committed Jun 28, 2022
1 parent 15ccaa6 commit e33ff7b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cogs/fairy.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ async def fairy(self, ctx):
else:
await ctx.respond('없어요ㅠㅠ')

with open(f'fairy_archive/{dt.datetime.now().strftime("%Y.%m")}.txt', 'a', encoding='euc-kr') as archive:
with open(f'fairy_archive/{dt.datetime.now().strftime("%Y.%m")}.txt', 'a') as archive:
archive.write(dt.datetime.now().strftime(f'%Y-%m-%dT%H:%M:%S <{ctx.author.name}> <{ctx.guild}> {ctx.author.id} {1 if is_fairy else 0}\n'))

@slash_command(name='요정소환')
Expand All @@ -86,7 +86,7 @@ async def summonFairy(self, ctx):
async def fairyRank(self, ctx):
"""`/지성이있나요` 명령어를 얼마나 사용했는지 알려줍니다."""

with open(f'fairy_archive/{dt.datetime.now().strftime("%Y.%m")}.txt', 'r', encoding='euc-kr') as archive:
with open(f'fairy_archive/{dt.datetime.now().strftime("%Y.%m")}.txt', 'r') as archive:
fairyCounter = dict()

while True:
Expand Down

0 comments on commit e33ff7b

Please sign in to comment.