Remove comments from XML

This commit is contained in:
SpreedBLood 2021-03-11 20:42:33 +01:00
parent b4a591b3a6
commit c0bd2fa6c1

View File

@ -54,7 +54,10 @@ export class SWFConverter extends Converter
if(!binaryData) return null;
return await parseStringPromise(binaryData.binaryData);
//Will fix some malformed comments exception.
const removedComments: string = binaryData.binaryData.replace(/<!--.*?-->/sg, '');
return await parseStringPromise(removedComments);
}
protected static async getAssetsXML(habboAssetSWF: HabboAssetSWF): Promise<any>