mirror of
https://github.com/DYefremov/DemonEditor.git
synced 2026-01-16 20:43:14 +01:00
removing bouquet file
This commit is contained in:
@@ -97,7 +97,7 @@ def telnet(host, port=23, user="root", password="root", timeout=1):
|
||||
time.sleep(timeout)
|
||||
command = yield
|
||||
tn.write("{}\r\n".format(command).encode("utf-8"))
|
||||
time.sleep(timeout)
|
||||
time.sleep(5) # need more time
|
||||
command = yield
|
||||
time.sleep(timeout)
|
||||
tn.write("{}\r\n".format(command).encode("utf-8"))
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
from contextlib import suppress
|
||||
|
||||
import os
|
||||
|
||||
from app.commons import run_task
|
||||
from app.eparser import get_channels, get_bouquets, write_bouquets, write_channels, Bouquets, Bouquet, Channel
|
||||
from app.properties import get_config, write_config
|
||||
@@ -206,6 +208,11 @@ class MainAppWindow:
|
||||
return
|
||||
else:
|
||||
self.__bouquets.pop(bq_selected)
|
||||
self.__fav_model.clear()
|
||||
# removing bouquet file
|
||||
bqf = "{}userbouquet.{}.{}".format(self.__options["data_dir_path"], *bq_selected.split(":"))
|
||||
with suppress(FileNotFoundError):
|
||||
os.remove(bqf)
|
||||
model.remove(itr)
|
||||
|
||||
if model_name == self._FAV_LIST_NAME:
|
||||
|
||||
Reference in New Issue
Block a user