snapback4 0.0.4 → 0.0.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/client.js +3 -1
  2. package/package.json +2 -2
package/dist/client.js CHANGED
@@ -178,7 +178,9 @@ export function createClient(options) {
178
178
  void refresh(watch);
179
179
  }
180
180
  else {
181
- entry.resolve({ state: "failed", id: entry.id, why: json.why ?? offline() });
181
+ // A 400 carries `denied` (an input or auth refusal), a judged write
182
+ // carries `why`; neither is the link's fault.
183
+ entry.resolve({ state: "failed", id: entry.id, why: json.why ?? json.denied ?? { code: "E_STORE", family: "store", message: "the server answered without a state", retryable: true } });
182
184
  }
183
185
  return true;
184
186
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "snapback4",
3
- "version": "0.0.4",
3
+ "version": "0.0.5",
4
4
  "type": "module",
5
5
  "description": "Snapback 4: the card (contract), the online and local-first clients (IndexedDB, SQLite), React hooks, sign-in, a labelled mock, and the `snapback4` CLI. LLP 3000.",
6
6
  "bin": {
@@ -42,7 +42,7 @@
42
42
  "README.md"
43
43
  ],
44
44
  "optionalDependencies": {
45
- "snapback4-darwin-arm64": "0.0.4"
45
+ "snapback4-darwin-arm64": "0.0.5"
46
46
  },
47
47
  "scripts": {
48
48
  "build": "tsc -p tsconfig.build.json",