Scrivito is proudly made by JustRelate Group in Berlin, Germany, and Wrocław, Poland.
Scrivito is proudly made by JustRelate Group

finishSaving()

Returns a promise that is resolved after local changes to the CMS object have been saved.

obj = Scrivito.getClass('BlogPost').create({title: "New features"});
await obj.finishSaving();
Waiting for finishSaving ensures that local changes have been successfully persisted by the Scrivito backend. This is not only useful after calling create to instantiate a CMS object, but also after an update.

Returns

Promise<void> – A promise that is resolved after the local changes to the object have been successfully persisted.

Throws

The returned promise is rejected if there was an error persisting the changes.