Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃悰 Configure command overrides optional parameters even if not specified #114

Closed
MarcusOtter opened this issue Mar 15, 2022 · 3 comments 路 Fixed by #250
Closed

馃悰 Configure command overrides optional parameters even if not specified #114

MarcusOtter opened this issue Mar 15, 2022 · 3 comments 路 Fixed by #250
Labels
confirmed bug 馃 Something isn't working

Comments

@MarcusOtter
Copy link
Owner

Describe the bug

The /configure auto-threading command has optional paremeters, such as include-bots and custom-message for example. If these options are left out when running /configure auto-threading, they will be set to the default value. This is annoying for example if users have set up a long custom message, but then remembers that they need to change another setting. The setting change would remove their custom message, so they have to write the entire command again.

Solution:
Instead of setting them to the default values, set them to the current values (or default if there are no current values).

Steps to reproduce the bug

  1. /configure auto-threading channel: #general custom-message: Here's a very long message!\n\nI sure hope I don't have to type this again.
  2. /configure auto-threading channel: #general include-bots: true
  3. Send message in #general
  4. Thread is not made with custom-message, it uses the default one

Expected behavior

Expected: custom-message is used for the auto-thread
Actual: The command on step 2 overwrote the custom-message to the default one since it was not provided

@MarcusOtter MarcusOtter added the confirmed bug 馃 Something isn't working label Mar 15, 2022
@MarcusOtter MarcusOtter pinned this issue Mar 15, 2022
@c43721
Copy link
Contributor

c43721 commented Jul 14, 2022

Sounds like a usecase that modals with selects would fix.

@MarcusOtter
Copy link
Owner Author

For sure!

@c43721
Copy link
Contributor

c43721 commented Jul 15, 2022

image
image

By reading the config first then applying null coalescing, we would fix this issue. We can solve that now if we require a quick patch.

Otherwise, wait for modals.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
confirmed bug 馃 Something isn't working
Projects
None yet
2 participants