Uncaught TypeError: contact.getWorldManifold is not a function

Uncaught TypeError: contact.getWorldManifold is not a function


this is cocos creator 3.8.2

I have no idea what the problem is
Hope someone can help me

*I found the problem
onBeginContact(selfCollider, otherCollider, contact){
const wm = contact.getWorldManifold();
}
onBeginContact should be like this.

Did you write the function wrongly?

onBeginContact (selfCollider:Collider2D, otherCollider:Collider2D, contact:IPhysics2DContact | null)