* Validates and sets a property / value combination. Will invoke the * callback if the value is not valid.
()
| 290 | * callback if the value is not valid. |
| 291 | */ |
| 292 | async function setAsync() { |
| 293 | try { |
| 294 | await resource.set(propertyURL, newVal, store, validate); |
| 295 | handleValidationError && handleValidationError(null); |
| 296 | // commit && (await resource.save(store)); |
| 297 | store.notify(resource); |
| 298 | } catch (e) { |
| 299 | handleValidationError ? handleValidationError(e) : console.log(e); |
| 300 | } |
| 301 | } |
| 302 | await setAsync(); |
| 303 | } |
| 304 |
no test coverage detected