diff --git a/src/v2/firestorm/textures/index.ts b/src/v2/firestorm/textures/index.ts index 09e4842..809f047 100644 --- a/src/v2/firestorm/textures/index.ts +++ b/src/v2/firestorm/textures/index.ts @@ -24,7 +24,9 @@ export const textures = firestorm.collection("textures", (el) => { el.paths = async (): Promise => el .uses() - .then((_uses) => Promise.all(_uses.map((_use) => uses.get(_use.id).then((u) => u.getPaths())))) + .then((_uses) => + Promise.all(_uses.map((_use) => uses.get(_use.id).then((u) => u.getPaths()))), + ) .then((arr) => arr.flat()); el.url = async (pack: KnownPacks, version: string): Promise => { diff --git a/src/v2/firestorm/textures/paths.ts b/src/v2/firestorm/textures/paths.ts index dc2e95f..d4daec5 100644 --- a/src/v2/firestorm/textures/paths.ts +++ b/src/v2/firestorm/textures/paths.ts @@ -1,8 +1,8 @@ import firestorm from "firestorm-db"; +import { Texture, Use } from "~/v2/interfaces"; import config from "../config"; import { uses } from "./uses"; -import { Texture, Use } from "~/v2/interfaces"; config(); diff --git a/src/v2/firestorm/textures/uses.ts b/src/v2/firestorm/textures/uses.ts index aaf95c0..7aafd6c 100644 --- a/src/v2/firestorm/textures/uses.ts +++ b/src/v2/firestorm/textures/uses.ts @@ -1,9 +1,9 @@ import firestorm from "firestorm-db"; +import { Paths, Texture } from "~/v2/interfaces"; import config from "../config"; import { textures } from "."; import { paths } from "./paths"; -import { Paths, Texture } from "~/v2/interfaces"; config(); diff --git a/src/v2/firestorm/users/index.ts b/src/v2/firestorm/users/index.ts index 8b9f0fd..5552cf3 100644 --- a/src/v2/firestorm/users/index.ts +++ b/src/v2/firestorm/users/index.ts @@ -8,7 +8,7 @@ config(); export const users = firestorm.collection("users", (el) => { el.contributions = async (): Promise => - await contributions.search([ + contributions.search([ { field: "authors", criteria: "array-contains", diff --git a/src/v2/repository/firestorm/path.repository.ts b/src/v2/repository/firestorm/path.repository.ts index 83a3193..b304168 100644 --- a/src/v2/repository/firestorm/path.repository.ts +++ b/src/v2/repository/firestorm/path.repository.ts @@ -28,7 +28,7 @@ export default class PathFirestormRepository implements PathRepository { } createPath(path: InputPath): Promise { - return paths.then((id) => paths.get(id)); + return paths.add(path).then((id) => paths.get(id)); } removePathById(path_id: string): Promise {