mirror of
https://iceshrimp.dev/limepotato/jormungandr-bite.git
synced 2024-11-14 14:07:38 -07:00
format
This commit is contained in:
parent
8c6f98cfc3
commit
a4b5726ecc
1 changed files with 5 additions and 1 deletions
|
@ -173,7 +173,11 @@ function validate(profile: unknown): void {
|
|||
if (!isObject(profile)) throw new Error("not an object");
|
||||
|
||||
// Check if unnecessary properties exist
|
||||
if (Object.keys(profile).some((key) => !profileProps.includes(key) && key !== "host"))
|
||||
if (
|
||||
Object.keys(profile).some(
|
||||
(key) => !profileProps.includes(key) && key !== "host"
|
||||
)
|
||||
)
|
||||
throw new Error("Unnecessary properties exist");
|
||||
|
||||
if (!profile.name) throw new Error("Missing required prop: name");
|
||||
|
|
Loading…
Reference in a new issue