* Check if a method call is known to mutate its receiver, and notify if so. * @param {Object} target - The object the method was called on * @param {string} methodName - The method name
(target, methodName)
| 2491 | * @param {string} methodName - The method name |
| 2492 | */ |
| 2493 | maybeNotify(target, methodName) { |
| 2494 | if (target == null || typeof target !== "object") return; |
| 2495 | var typeName = target.constructor && target.constructor.name; |
| 2496 | var methods = typeName && config.mutatingMethods[typeName]; |
| 2497 | if (methods && methods.includes(methodName)) { |
| 2498 | this.notifyMutation(target); |
| 2499 | } |
| 2500 | } |
| 2501 | #trackMutation(val) { |
| 2502 | if (this.reactivity.isTracking && val != null && typeof val === "object") { |
| 2503 | this.reactivity.trackProperty(val, "__mutation__"); |
no test coverage detected