Skip to content

Update topic_cmd.cpp#28

Open
squidlox wants to merge 1 commit into
cppdiscord:mainfrom
squidlox:FileLoading
Open

Update topic_cmd.cpp#28
squidlox wants to merge 1 commit into
cppdiscord:mainfrom
squidlox:FileLoading

Conversation

@squidlox
Copy link
Copy Markdown

@squidlox squidlox commented May 8, 2026

may help mitigate file loading errors

Adds a for loop to topic_cmd.cpp that will retry loading the topic string if it is empty.

adds one int variable for max load attempts in the for loop. this is needed to keep the bot from looping infinitely in the case the file is not able to be loaded.

Shouldn't break anything but I'm new so please check extra carefully

may help mitigate file loading errors
@xNoerPlaysCodes
Copy link
Copy Markdown
Contributor

looks good to me but I'm not a maintainer :(

@xNoerPlaysCodes
Copy link
Copy Markdown
Contributor

It's kind of a band-aid fix, but it probably works; I made a PR with a completely new function and system of handling opening the file, so you might want to look into that, but then again THAT might not be merged so this is also a good enough solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants