Console error after upgrading to v1.15.2

default discord avatar
dh3627
3 weeks ago
3

Hi all, I upgraded from Payload v1.8.2 to v.1.15.2 and everything looks fine except on one of my collections I am getting a lot of these messages in my console log:



react-dom.development.js:86 Warning: You provided a

checked

prop to a form field without an

onChange

handler. This will render a read-only field. If the field should be mutable use

defaultChecked

. Otherwise, set either

onChange

or

readOnly

.



One of the checkbox fields affected is this one:



{


name: 'displayCreationImages',


type: 'checkbox',


defaultValue: false,


admin: {


description: 'example description',


},


},



I've checked the Payload docs and it seems to be correct so I'm not sure what's causing the errors.



Can anyone advise on how to fix this please?

  • discord user avatar
    jarrod_not_jared
    Payload Team
    3 weeks ago

    Yeah I think there is a ticket pulled for this, if not I am getting v annoyed by it and will likely fix it today.



    PR here:

    https://github.com/payloadcms/payload/pull/3291
  • discord user avatar
    seanzubrickas
    Payload Team
    2 weeks ago

    Hey @dh3627 just an FYI the PR that fixes this was merged - so make sure you have the latest update and you should be good to go.

  • default discord avatar
    dh3627
    2 weeks ago

    Thanks guys, I'll update later today and give it a try

Open the post
Continue the discussion in Discord
Like what we're doing?
Star us on GitHub!

Star

Connect with the Payload Community on Discord

Discord

online

Can't find what you're looking for?

Get help straight from the Payload team with an Enterprise License.