|
|
@@ -638,6 +638,11 @@ class Storage: |
|
|
|
self.config = config |
|
|
|
self.paths = {channel['ircchannel']: channel['path'] for channel in self.config['channels'].values()} |
|
|
|
|
|
|
|
# Since the PART messages will still arrive for the removed channels, only close those files after a little while. |
|
|
|
asyncio.create_task(self.delayed_close_files(channelsRemoved)) |
|
|
|
|
|
|
|
async def delayed_close_files(self, channelsRemoved): |
|
|
|
await asyncio.sleep(10) |
|
|
|
for channel in channelsRemoved: |
|
|
|
if channel in self.files: |
|
|
|
self.logger.debug(f'Closing file for {channel!r}') |
|
|
|