Skip to content

VaultTransaction.modify method

VaultTransaction › modify

Replaces the content of a file, capturing the old content so it can be restored on rollback.

Signature:

modify(pathOrFile: PathOrAbstractFile, newContent: string): Promise<void>

Parameters:

ParameterTypeDescription
pathOrFilePathOrAbstractFileThe path or file to modify.
newContentstringThe new content.

Returns: Promise<void>A Promise that resolves when the file is modified.