mirror of
https://github.com/outline/outline.git
synced 2026-12-06 19:22:29 +03:00
fix: Cannot read properties of null (reading '0')
This commit is contained in:
1 parent
c990ace2e2
commit
9a94e2dcf2
1 file changed
+5
-1
@@ -102,7 +102,11 @@ export class UploadPlugin extends Plugin {
|
||||
// find any remote images in pasted slice, but leave it alone.
|
||||
const images: Node[] = [];
|
||||
slice.content.descendants((node) => {
|
||||
if (node.type.name === "image" && !isInternalUrl(node.attrs.src)) {
|
||||
if (
|
||||
node.type.name === "image" &&
|
||||
node.attrs.src &&
|
||||
!isInternalUrl(node.attrs.src)
|
||||
) {
|
||||
images.push(node);
|
||||
}
|
||||
});
|
||||
|
||||
Reference in new issue
Block a user