This commit is contained in:
@@ -20,6 +20,7 @@
|
||||
import {fetchWithToken, tokenStore} from "./repo.ts";
|
||||
import {type Schematic, SchematicSchema} from "@type/schem.ts";
|
||||
import {derived} from "svelte/store";
|
||||
import {ResponseErrorSchema} from "@type/data.ts";
|
||||
|
||||
export class SchematicRepo {
|
||||
constructor(private token: string) {
|
||||
@@ -40,7 +41,7 @@ export class SchematicRepo {
|
||||
name,
|
||||
content,
|
||||
}),
|
||||
});
|
||||
}).then(value => value.json()).then(SchematicSchema.or(ResponseErrorSchema).parse);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user