Skip to content

fix(collections): validate virtual fields in useAsTitle for auth collections (#16142)#16190

Open
deepshekhardas wants to merge 1 commit intopayloadcms:mainfrom
deepshekhardas:fix/16142-useastitle-auth-validation
Open

fix(collections): validate virtual fields in useAsTitle for auth collections (#16142)#16190
deepshekhardas wants to merge 1 commit intopayloadcms:mainfrom
deepshekhardas:fix/16142-useastitle-auth-validation

Conversation

@deepshekhardas
Copy link
Copy Markdown
Contributor

Fixes #16142 - useAsTitle virtual field validation is skipped if collection has auth enabled

Problem: Virtual field validation was being skipped for auth-enabled collections, allowing virtual fields to be used as title which breaks relationship searching

Solution: Moved virtual field validation outside the auth check so it applies to all collections

…ections (payloadcms#16142)

Virtual field validation was being skipped for auth-enabled collections

Now properly validates virtual fields for all collections including auth

Fixes payloadcms#16142
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 7, 2026

Pull Request titles must follow the Conventional Commits specification and have valid scopes.

Unknown scope "collections" found in pull request title "fix(collections): validate virtual fields in useAsTitle for auth collections (#16142)". Scope must match one of: cpa, claude, db-*, db-d1-sqlite, db-mongodb, db-postgres, db-vercel-postgres, db-sqlite, db-d1-sqlite, drizzle, email-*, email-nodemailer, email-resend, eslint, graphql, kv, kv-redis, live-preview, live-preview-react, live-preview-vue, next, payload-cloud, plugin-cloud, plugin-cloud-storage, plugin-ecommerce, plugin-form-builder, plugin-import-export, plugin-mcp, plugin-multi-tenant, plugin-nested-docs, plugin-redirects, plugin-search, plugin-sentry, plugin-seo, plugin-stripe, richtext-*, richtext-lexical, richtext-slate, sdk, storage-*, storage-azure, storage-gcs, storage-r2, storage-uploadthing, storage-vercel-blob, storage-s3, translations, ui, templates, examples(/(\w|-)+)?, deps.

feat(ui): add Button component
^    ^    ^
|    |    |__ Subject
|    |_______ Scope
|____________ Type

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

useAsTitle virtual field validation is skipped if collection has auth enabled

1 participant