Skip to content

Commit 794cd91

Browse files
committed
refactor: 精简代码
1 parent e91fabf commit 794cd91

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

src/components/BootstrapBlazor.SummerNote/Components/Editor/Editor.razor.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,7 @@ export async function init(id, invoker, methodGetPluginAttrs, methodClickPluginI
5151
editor.files = files
5252
for (let i = 0; i < files.length; i++) {
5353
const file = files[i];
54-
const buffer = await file.arrayBuffer();
55-
const stream = DotNet.createJSStreamReference(buffer);
54+
const stream = DotNet.createJSStreamReference(file);
5655
const url = await editor.invoker.invokeMethodAsync('ImageUpload',
5756
file.name,
5857
file.type || 'application/octet-stream',

0 commit comments

Comments
 (0)