I am building a LWC that displays Case Comments and also allow users to create new Case Comments. I am having a lot of issues with isPublished on record insert. For some reason it is giving me the error above. I can save a CaseComment if the object i am passing to apex doesn't have the isPublished field included (the field is tied to a checkbox so if users don't select it, it isn't in the object passed to Apex)
However i can run anonymous apex and it inserts a CaseComment record without issue.
insert new CaseComment(ParentId = '50002000000Ub7OAAS', CommentBody = 'the second time', isPublished = true);
I am the system admin and have all privileges on Case, though I shouldn't need to for this field per the CaseComment api documentation
Any thoughts on what is causing this error?