-
-
Notifications
You must be signed in to change notification settings - Fork 45
Post-refactoring and improving of the new batch tags update flow #580
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
base: master
Are you sure you want to change the base?
Post-refactoring and improving of the new batch tags update flow #580
Conversation
|
You should've asked me why there was mass_revert_tags... I intend to implement per-tag reverts as a mod tool in the future, so that mods can select individual tags to be reverted as opposed to whole batches. Hence why this whole structure and tag_changes relation preloads on TagChanges.Tag. |
13a8114 to
3d1e53e
Compare
|
Split refactoring / logic fixes, and unit tests, into two separate PRs, this PR is becoming way too large. Maybe even more PRs to be honest, your initial fixes were small and easily mergeable, but this has gotten really, really huge now. |
24d2985 to
73eaa68
Compare
…ntly probably not the intended behavior?
73eaa68 to
bc24332
Compare
There are several changes packed in this single PR
Zero changes edge case
Fixed this edge case when the user doesn't select any tags to revert at all and clicks on the "Revert selected" button:

(this bug should active be in prod too).
Eliminate redundant preloads
I removed the redundant
:tagand:tag_change(reverse) preloads for the initialTagChangeselect. The insideImages.batch_updatedoesn't need the fullTagChange.Tagstruct, it can simply work with tag_ids lists.More info in the flash
Also added the number of actually updated tags to the result of the revert:

TODO
I'll try to add some auto tests for this code