mirror of
https://github.com/EchoSixHIYA/WebSpeak-client-for-TeamSpeak.git
synced 2026-12-03 12:02:50 +08:00
Fix workshop installs and make plugin configuration editable
This commit is contained in:
1 parent
6a35d9be3d
commit
274bd81dc3
13 files changed
+389
-32
No files matched your search
@@ -134,8 +134,8 @@ export class SkinStore {
|
||||
const bytes = await this.download(`${source.repository.replace("https://github.com/", "https://raw.githubusercontent.com/")}/${metadata.package.ref}/${metadata.package.path}`, MAX_PACK_BYTES);
|
||||
if (createHash("sha256").update(bytes).digest("hex") !== metadata.package.sha256) return fail("SKIN_STORE_CHECKSUM");
|
||||
const { manifest } = validateSkinArchive(bytes, input.id);
|
||||
for (const key of ["id", "name", "version", "author", "license", "minAppVersion"] as const) {
|
||||
if (manifest[key] !== metadata[key]) return fail("SKIN_STORE_PACKAGE_MISMATCH");
|
||||
if (manifest.version !== metadata.version || manifest.minAppVersion !== metadata.minAppVersion) {
|
||||
return fail("SKIN_STORE_PACKAGE_MISMATCH");
|
||||
}
|
||||
return registry.save(bytes, input.id);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user