Some Code Cleanup
This commit is contained in:
@@ -18,8 +18,8 @@
|
||||
*/
|
||||
|
||||
import {fetchWithToken} from "./repo.ts";
|
||||
import type {SchematicCode, SchematicInfo, SchematicList} from "../types/schem.ts";
|
||||
import {SchematicCodeSchema, SchematicInfoSchema, SchematicListSchema} from "../types/schem.ts";
|
||||
import type {SchematicCode, SchematicInfo, SchematicList} from "@type/schem.ts";
|
||||
import {SchematicCodeSchema, SchematicInfoSchema, SchematicListSchema} from "@type/schem.ts";
|
||||
|
||||
export class SchematicRepo {
|
||||
constructor(private token: string) {}
|
||||
@@ -41,12 +41,12 @@ export class SchematicRepo {
|
||||
}
|
||||
|
||||
public async uploadSchematic(name: string, content: string) {
|
||||
return await fetchWithToken(this.token, `/schem`, {
|
||||
return await fetchWithToken(this.token, "/schem", {
|
||||
method: "POST",
|
||||
body: JSON.stringify({
|
||||
name,
|
||||
content
|
||||
})
|
||||
})
|
||||
});
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user