diff --git a/README.md b/README.md index 697f362..98ffa21 100644 --- a/README.md +++ b/README.md @@ -201,4 +201,4 @@ Blog: https://blog.rune.pm ## Support -For issues, questions, or contributions, visit https://iurl.no/oai \ No newline at end of file +For issues, questions, or contributions, visit https://iurl.no/oai and create an issue. \ No newline at end of file diff --git a/oai.py b/oai.py index d85e84b..f943643 100644 --- a/oai.py +++ b/oai.py @@ -642,10 +642,8 @@ def chat(): console.print("[bold yellow]No change.[/]") except Exception as e: console.print(f"[bold red]Error updating URL: {e}[/]") - elif args == "costwarning": - sub_args = user_input[8 + len("costwarning"):].strip() # From after "costwarning" - if sub_args == "costwarning": - sub_args = "" # No value provided + elif args.startswith("costwarning"): + sub_args = args[11:].strip() # Extract everything after "costwarning" if not sub_args: console.print(f"[bold blue]Stored cost warning threshold: ${COST_WARNING_THRESHOLD:.4f}[/]") continue