Skip to content

Commit

Permalink
update all other reset
Browse files Browse the repository at this point in the history
  • Loading branch information
DenisCarriere committed Feb 21, 2024
1 parent 727c661 commit ade8c18
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions sql/cursor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,12 @@ async function paramsLatestCursor(req: Request) {
if (!module_hash) throw new Error("Missing parameter: module_hash");

if (!(await store.query_chains()).includes(chain)) {
store.reset();
await store.reset("chains");
throw new Error("Invalid parameter: chain=" + chain);
}

if (!(await store.query_module_hashes()).includes(module_hash)) {
store.reset();
await store.reset("module_hashes");
throw new Error("Invalid parameter: module_hash=" + module_hash);
}

Expand Down
2 changes: 1 addition & 1 deletion src/fetch/DELETE.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ export default async function (req: Request): Promise<Response> {
const { pathname } = new URL(req.url);

if (pathname === "/caches") {
store.reset();
await store.reset("all");
return new Response();
}

Expand Down

0 comments on commit ade8c18

Please sign in to comment.