MCPcopy Index your code
hub / github.com/atomicdata-dev/atomic-data-browser / removePropVal

Method removePropVal

lib/src/resource.ts:227–238  ·  view source on GitHub ↗

Removes a property value combination from the resource and adds it to the next Commit

(propertyUrl: string)

Source from the content-addressed store, hash-verified

225
226 /** Removes a property value combination from the resource and adds it to the next Commit */
227 removePropVal(propertyUrl: string): void {
228 // Delete from this resource
229 this.propvals.delete(propertyUrl);
230 // Delete possible item from the commitbuilder set object
231 try {
232 delete this.commitBuilder.set[propertyUrl];
233 } catch (e) {
234 console.log('Item not present in commitbuilder.set');
235 }
236 // Add it to the array of items that the server might need to remove after posting.
237 this.commitBuilder.remove.push(propertyUrl);
238 }
239
240 /**
241 * Removes a property value combination from this resource, does not store the

Callers 2

validateAndSetFunction · 0.80
handleDeleteFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected