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

Fix performer validation #4248

Merged

Conversation

DingDongSoLong4
Copy link
Collaborator

@DingDongSoLong4 DingDongSoLong4 commented Oct 26, 2023

This improves/fixes the validation on performer create/update, and packages everything into convenient ValidateCreate and ValidateUpdate functions that are then used in the resolvers.

The main issue fixed is that performers were able to conflict with themselves when updating, causing the issue in #4229.

I've then also added a check to error on an empty name, which is enforced in the UI but not in the backend.

Similar changes to the validation for the other object types (studios, tags, etc) will come in the future.

Fixes #4229
Fixes #4250

@DingDongSoLong4
Copy link
Collaborator Author

Added case-insensitive duplicate alias validation. Fixes #4250

@WithoutPants WithoutPants added this to the Version 0.24.0 milestone Nov 2, 2023
@WithoutPants WithoutPants added the bug Something isn't working label Nov 2, 2023
@WithoutPants WithoutPants merged commit 4715c5e into stashapp:develop Nov 2, 2023
@DingDongSoLong4 DingDongSoLong4 deleted the fix-performer-validation branch November 2, 2023 10:31
halkeye pushed a commit to halkeye/stash that referenced this pull request Sep 1, 2024
* Fix performer validation
* Add tests
* Rename QueryCount argument
* Minor refactoring
* Add duplicate alias validation
* Make UI alias validation also case-insensitive
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
2 participants