mirror of
https://github.com/usmannasir/cyberpanel.git
synced 2025-11-07 05:45:59 +01:00
Minor bug fix to API
This commit is contained in:
@@ -50,13 +50,16 @@ class SetupConn:
|
||||
try:
|
||||
self.sock.listen(5)
|
||||
while True:
|
||||
# Wait for a connection
|
||||
if os.path.exists(SetupConn.cleaningPath):
|
||||
readFromFile = open(SetupConn.cleaningPath, 'r')
|
||||
command = readFromFile.read()
|
||||
cacheManager.handlePurgeRequest(command)
|
||||
readFromFile.close()
|
||||
os.remove(SetupConn.cleaningPath)
|
||||
try:
|
||||
# Wait for a connection
|
||||
if os.path.exists(SetupConn.cleaningPath):
|
||||
readFromFile = open(SetupConn.cleaningPath, 'r')
|
||||
command = readFromFile.read()
|
||||
cacheManager.handlePurgeRequest(command)
|
||||
readFromFile.close()
|
||||
os.remove(SetupConn.cleaningPath)
|
||||
except:
|
||||
pass
|
||||
|
||||
connection, client_address = self.sock.accept()
|
||||
background = handle.HandleRequest(connection)
|
||||
|
||||
Reference in New Issue
Block a user