Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions web/packages/core/src/internal/player/inner.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2104,13 +2104,12 @@ export class InnerPlayer {
`Error stack:\n\`\`\`\n${error.stack}\n\`\`\`\n`,
) - 1;
if (error.avmStack) {
const avmStackIndex =
errorArray.avmStackIndex =
errorArray.push(
`AVM2 stack:\n\`\`\`\n ${error.avmStack
.trim()
.replace(/\t/g, " ")}\n\`\`\`\n`,
) - 1;
errorArray.avmStackIndex = avmStackIndex;
}
errorArray.stackIndex = stackIndex;
}
Expand Down Expand Up @@ -2531,8 +2530,7 @@ function base64ToArray(bytesBase64: string): Uint8Array<ArrayBuffer> {
*/
function base64ToBlob(bytesBase64: string, mimeString: string): Blob {
const ab = base64ToArray(bytesBase64);
const blob = new Blob([ab], { type: mimeString });
return blob;
return new Blob([ab], { type: mimeString });
}

/**
Expand Down
3 changes: 1 addition & 2 deletions web/packages/core/src/swf-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,5 @@ export function isSwf(filename: string, mimeType: string | null): boolean {
*/
export function swfFileName(swfUrl: URL): string {
const pathName = swfUrl.pathname;
const name = pathName.substring(pathName.lastIndexOf("/") + 1);
return name;
return pathName.substring(pathName.lastIndexOf("/") + 1);
}
5 changes: 3 additions & 2 deletions web/packages/extension/src/common.ts
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,9 @@ class SelectOption implements OptionElement<string | null> {
// Convert `null` to the empty string.
value ??= "";
const options = Array.from(this.select.options);
const index = options.findIndex((option) => option.value === value);
this.select.selectedIndex = index;
this.select.selectedIndex = options.findIndex(
(option) => option.value === value,
);
}
}

Expand Down
Loading