UNPKG

@loopback/docs

Version:
37 lines (23 loc) 1.02 kB
--- lang: en title: 'API docs: repository.entitycrudrepository.update' keywords: LoopBack 4.0, LoopBack 4 sidebar: lb4_sidebar permalink: /doc/en/lb4/apidocs.repository.entitycrudrepository.update.html --- <!-- Do not edit this file. It is automatically generated by API Documenter. --> [Home](./index.md) &gt; [@loopback/repository](./repository.md) &gt; [EntityCrudRepository](./repository.entitycrudrepository.md) &gt; [update](./repository.entitycrudrepository.update.md) ## EntityCrudRepository.update() method Update an entity <b>Signature:</b> ```typescript update(entity: DataObject<T>, options?: Options): Promise<void>; ``` ## Parameters | Parameter | Type | Description | | --- | --- | --- | | entity | <code>DataObject&lt;T&gt;</code> | Entity to be updated | | options | <code>Options</code> | Options for the operations | <b>Returns:</b> `Promise<void>` A promise that will be resolve if the operation succeeded or will be rejected if the entity was not found.