mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2025-04-26 11:35:15 +01:00
Fix crash with generating fused species name
This commit is contained in:
parent
f16f4576fe
commit
efb957cd4b
@ -78,7 +78,7 @@ export function getFusedSpeciesName(speciesAName: string, speciesBName: string):
|
|||||||
fragB = fragB.slice(1);
|
fragB = fragB.slice(1);
|
||||||
else {
|
else {
|
||||||
const newCharMatch = new RegExp(`[^${lastCharA}]`).exec(fragB);
|
const newCharMatch = new RegExp(`[^${lastCharA}]`).exec(fragB);
|
||||||
if (newCharMatch.index > 0)
|
if (newCharMatch?.index > 0)
|
||||||
fragB = fragB.slice(newCharMatch.index);
|
fragB = fragB.slice(newCharMatch.index);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user