Skip to content

Commit

Permalink
fix: Ensure filename obfuscation works with obfuscation
Browse files Browse the repository at this point in the history
  • Loading branch information
ebariche committed Sep 7, 2023
1 parent a795b2a commit 4aaf7eb
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/Uno.Wasm.Bootstrap/ts/Uno/WebAssembly/Bootstrapper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -436,7 +436,11 @@ namespace Uno.WebAssembly.Bootstrap {
}

private async deobfuscateFile(asset: string, response: Promise<void | Response>): Promise<void | Response> {
if (this._unoConfig.assemblyObfuscationKey && asset.endsWith(this._unoConfig.assemblyFileExtension)) {
const assemblyFileSuffix = this._unoConfig.assemblyFileNameObfuscationMode !== "NoDots" ?
this._unoConfig.assemblyFileExtension :
this._unoConfig.assemblyFileExtension.replace(".", "_");

if (this._unoConfig.assemblyObfuscationKey && asset.endsWith(assemblyFileSuffix)) {
const responseValue = await response;

if (responseValue) {
Expand Down

0 comments on commit 4aaf7eb

Please sign in to comment.