mirror of
https://github.com/smogon/pokemon-showdown.git
synced 2026-04-26 18:57:15 -05:00
Sim: Verbosely debug validator effectType mismatches
This commit is contained in:
parent
f4a7f092f6
commit
8b1efe7e45
|
|
@ -325,7 +325,7 @@ export class TeamValidator {
|
||||||
constructor(format: string | Format, dex = Dex) {
|
constructor(format: string | Format, dex = Dex) {
|
||||||
this.format = dex.formats.get(format);
|
this.format = dex.formats.get(format);
|
||||||
if (this.format.effectType !== 'Format') {
|
if (this.format.effectType !== 'Format') {
|
||||||
throw new Error(`format should be a 'Format', but was a '${this.format.effectType}'`);
|
throw new Error(`format '${format}' should be a 'Format', but was a '${this.format.effectType}'`);
|
||||||
}
|
}
|
||||||
this.dex = dex.forFormat(this.format);
|
this.dex = dex.forFormat(this.format);
|
||||||
this.gen = this.dex.gen;
|
this.gen = this.dex.gen;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user