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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Keira upon Execute & Copy doesn't care if the execution is correct or not refering to the clipboard #3175

Open
TheSCREWEDSoftware opened this issue Nov 21, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@TheSCREWEDSoftware
Copy link
Contributor

TheSCREWEDSoftware commented Nov 21, 2024

I don't know what to qualify this as a bug or a enchancement.

I used this on creature_template and SAI so either of them will work for this example.

  • Have this number in your clipboard 11625
  • Go to Creature Template
  • Search for ID 11625 (reflects to be: Cork Gizelton, click him
  • Any value that's required (can't be null), let's use minlevel either remove it (and keep it blank) or use a negative number like -1
  • Press Execute & Copy
  • You will get the SQL error and now your clipboard still got overwrriten by the command.
    You went from 11625 to (example) below:
UPDATE `creature_template` SET `minlevel` = -1 WHERE (`entry` = 11625); 

I'm not sure how it works in TypeScript.

Have a variable with the query (even if wrong).

Check if the query is correct, if yes, execute it, and grab the query and overwrite the user's clipboard.

If the query is not correct or there's an issue executing (for some reason), don't touch the user's clipboard

(if you tell me where this comparasition happens i can probably fix it and submit a PR)

@TheSCREWEDSoftware TheSCREWEDSoftware changed the title Keira upon Execute & Copy doesn't care if the execution is correct or not. Keira upon Execute & Copy doesn't care if the execution is correct or not refering to the clipboard Nov 21, 2024
@Helias Helias added the enhancement New feature or request label Nov 21, 2024
@Helias
Copy link
Member

Helias commented Nov 21, 2024

right now we don't do a comparison, we execute the SQL query and at the same time we make the copy, we should make a proper function to do this check I think

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants