提交 68ba13d0 编写于 作者: D Don Jayamanne

Remove window keyword from serializer

上级 b2f85176
......@@ -276,7 +276,7 @@ function convertOutputMimeToJupyterOutput(mime: string, value: Uint8Array) {
if (typeof Buffer !== 'undefined' && typeof Buffer.from === 'function') {
return Buffer.from(value).toString('base64');
} else {
return window.btoa(value.reduce((s: string, b: number) => s + String.fromCharCode(b), ''));
return btoa(value.reduce((s: string, b: number) => s + String.fromCharCode(b), ''));
}
} else if (mime.toLowerCase().includes('json')) {
const stringValue = textDecoder.decode(value);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册