mirror of
https://github.com/KeksPirates/SoftwareManager.git
synced 2026-08-04 17:59:43 +02:00
fix updater
This commit is contained in:
@@ -13,11 +13,17 @@ def restart_aria2c():
|
|||||||
atexit.unregister(kill_aria2server)
|
atexit.unregister(kill_aria2server)
|
||||||
atexit.register(kill_aria2server)
|
atexit.register(kill_aria2server)
|
||||||
|
|
||||||
def save_settings(thread_count, close, apiurl, download_path, speed_limit):
|
def save_settings(thread_count=None, close=lambda: None, apiurl=None, download_path=None, speed_limit=None, version=None):
|
||||||
|
if thread_count is not None:
|
||||||
state.aria2_threads = thread_count
|
state.aria2_threads = thread_count
|
||||||
|
if apiurl is not None:
|
||||||
state.api_url = apiurl
|
state.api_url = apiurl
|
||||||
|
if download_path is not None:
|
||||||
state.download_path = download_path
|
state.download_path = download_path
|
||||||
|
if speed_limit is not None:
|
||||||
state.speed_limit = speed_limit
|
state.speed_limit = speed_limit
|
||||||
|
if version is not None:
|
||||||
|
state.version = version
|
||||||
|
|
||||||
create_config()
|
create_config()
|
||||||
restart_aria2c()
|
restart_aria2c()
|
||||||
|
|||||||
Reference in New Issue
Block a user