remove old PEER files

This commit is contained in:
KF7EEL 2022-09-30 15:09:49 -07:00
parent 7d7cea8447
commit c80b6bc265
2 changed files with 2 additions and 0 deletions

View File

@ -1822,6 +1822,7 @@ if __name__ == '__main__':
# Create folder so hbnet.py can access list PEER connections
print(CONFIG['LOGGER']['LOG_NAME'])
if Path('/tmp/' + (CONFIG['LOGGER']['LOG_NAME'] + '_PEERS/')).exists():
os.remove('/tmp/' + (CONFIG['LOGGER']['LOG_NAME'] + '_PEERS/*'))
pass
else:
Path('/tmp/' + (CONFIG['LOGGER']['LOG_NAME'] + '_PEERS/')).mkdir()

View File

@ -1153,6 +1153,7 @@ if __name__ == '__main__':
# Create folder so hbnet.py can access list PEER connections
if Path('/tmp/' + (CONFIG['LOGGER']['LOG_NAME'] + '_PEERS/')).exists():
os.remove('/tmp/' + (CONFIG['LOGGER']['LOG_NAME'] + '_PEERS/*'))
pass
else:
Path('/tmp/' + (CONFIG['LOGGER']['LOG_NAME'] + '_PEERS/')).mkdir()