Hi there,
I see a syntax error, the save promise should be outside the onBeforeSave( ) function, putting it inside will create an infinite loop.
The save( ) function triggers the onBeforeSave( ) , so you shouldn’t place it inside it.
Please share the page URL so we can take a deeper look.