Fix build

This commit is contained in:
Sakura Knoll
2022-07-06 03:43:26 +09:00 Unverified
parent 6dcdb79ff3
commit 814ec0c081
3 changed files with 10 additions and 6 deletions
+2 -2
View File
@@ -70,7 +70,7 @@ export function getSignetGroupById(id: string, locale = 'en-US') {
let cachedSupports: any = null
export function getSupportBattlesuits(locale?: string): SupportBattlesuit[] {
if (cachedSignetGroupMap == null) {
if (cachedSupports == null) {
cachedSupports = yaml.parse(
fs
.readFileSync(
@@ -97,7 +97,7 @@ export function getSupportBattlesuits(locale?: string): SupportBattlesuit[] {
let cachedSigils: any = null
export function getRemembranceSigils(locale?: string): RemembranceSigil[] {
if (cachedSignetGroupMap == null) {
if (cachedSigils == null) {
cachedSigils = yaml.parse(
fs
.readFileSync(path.join(process.cwd(), 'data/honkai3rd/er-sigils.yaml'))
+5 -3
View File
@@ -120,9 +120,11 @@ export function getStigmataSetBySetId(setId: string, locale?: string) {
}
export function getStigmataListBySetId(setId: string, locale?: string) {
return ['top', 'mid', 'bot'].map((type) => {
return getStigmaById(setId + '-' + type, locale)!
})
return ['top', 'mid', 'bot']
.map((type) => {
return getStigmaById(setId + '-' + type, locale)!
})
.filter((stigma) => stigma != null)
}
export function getStigmataMapByIds(idList: string[], locale?: string) {