Change a regular task to unscheduled failed

hello,I have a problem to update a regular task to unscheduled task. my code snippet and js error are showed on below, any help will be appreciated.

this is error

Probably, the issue is related to the Gantt configuration, but it is hard to suggest what might be wrong as I don’t see your code with the Gantt configuration and how you unschedule tasks.
Please add your configuration to the following snippet and make sure that the issue is reproduced there:

Then, click on the Save button and send me the link.
Or send me a ready demo with all the necessary JavaScript and CSS files so that I can reproduce the issue locally.