#18162·payload

Account view crashes with "Cannot use 'in' operator to search for 'hidden' in undefined" on a minimal auth collection (3.89.0, Next 16.3.4)

Author: pattoliCreated Sep 11, 2026Updated Sep 11, 2026
Labelsarea: uiBug

Describe the Bug

After creating the first user, Payload redirects to /admin/account. That view throws during server render and the app's error boundary catches it. Every other admin view (collections list, list view, edit, create) renders fine for the same user.

Stack (production, Vercel, Node 22):

TypeError: Cannot use 'in' operator to search for 'hidden' in undefined
    at fieldIsHiddenOrDisabled (payload/dist/fields/config/types.js:41)
    at renderField (@payloadcms/ui/dist/forms/fieldSchemasToFormState/renderField.js:153)   // fieldIsHiddenOrDisabled(clientField)
    at addFieldStatePromise → iterateFields → buildFormState
    at Account view (@payloadcms/next/dist/views/Account/index.js:83, renderAllFields: true, schemaPath: collectionConfig.slug)

clientField comes from clientFieldSchemaMap.get(schemaPath) and is undefined for at least one field the server-side iteration visits, so the hidden/disabled check dereferences undefined.

Link to the code that reproduces this issue

Auth collection with no custom fields:

typescript
export const Users: CollectionConfig = {
  slug: "users",
  auth: true,
  admin: { useAsTitle: "email" },
  fields: [],
};

Config: postgresAdapter, lexicalEditor(), sharp, custom routes.admin, one other collection (posts, plain text/textarea/date/select/richText fields). Import map regenerated for 3.89.0. Single copy of every @payloadcms/* package (npm ls deduped).

Reproduction Steps

  1. Fresh database, config above, payload + @payloadcms/next + @payloadcms/ui + @payloadcms/db-postgres + @payloadcms/richtext-lexical all 3.89.0, next 16.3.4.
  2. Open the admin, complete /create-first-user.
  3. Land on /admin/account → server error above. Navigating to /admin/collections/users/<id> or /admin/collections/posts works.

Which area(s) are affected?

area: ui

Environment Info

bash
payload 3.89.0, @payloadcms/next 3.89.0, @payloadcms/ui 3.89.0, @payloadcms/db-postgres 3.89.0, @payloadcms/richtext-lexical 3.89.0
next 16.3.4 (Turbopack), react 19.2.4
node 22 (Vercel serverless), postgres (Supabase)