Skip to content

Commit

Permalink
- updating CLI to new configuration requirements
Browse files Browse the repository at this point in the history
  • Loading branch information
EchterAlsFake committed Nov 5, 2024
1 parent e45158f commit 492bfbe
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions Porn_Fetch_CLI.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def __init__(self):
self.menu()

def license(self):
if not self.conf["License"]["accepted"] == "true":
if not self.conf["Setup"]["license_accepted"] == "true":
license_text = input(f"""{Fore.WHITE}
GPL License Agreement for Porn Fetch
This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
Expand All @@ -68,13 +68,13 @@ def license(self):
---------------------------------->:""")

if license_text == "yes":
self.conf.set("License", "accepted", "true")
with open("config.ini", "w") as config_file:
self.conf.set("Setup", "license_accepted", "true")
with open("config.ini", "w") as config_file: #type: TextIOWrapper
self.conf.write(config_file)

else:
self.conf.set("License", "accepted", "false")
with open("config.ini", "w") as config_file:
self.conf.set("Setup", "license_accepted", "false")
with open("config.ini", "w") as config_file: #type: TextIOWrapper
self.conf.write(config_file)

sys.exit()
Expand Down Expand Up @@ -272,7 +272,7 @@ def save_user_settings(self):
self.menu()

finally:
with open("config.ini", "w") as config_file:
with open("config.ini", "w") as config_file: #type: TextIOWrapper
self.conf.write(config_file)

def process_video(self, url=None):
Expand Down

0 comments on commit 492bfbe

Please sign in to comment.