0
0
mirror of https://github.com/sveltejs/svelte.git synced 2024-11-30 00:46:29 +01:00

Update store.js

This commit is contained in:
Dmitry Kurmanov 2018-09-27 19:51:08 +03:00 committed by GitHub
parent b5140cdad3
commit 74b11a6389
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -162,7 +162,7 @@ assign(Store.prototype, {
let dirty = false;
for (const key in newState) {
if (this._computed[key]) throw new Error(`'${key}' is a read-only property`);
if (this._computed[key]) throw new Error(`'${key}' is a read-only computed property`);
if (this._differs(newState[key], oldState[key])) changed[key] = dirty = true;
}
if (!dirty) return;