Dont return an array from linkify if the result is just a single node
This commit is contained in:
parent
8684e2dea2
commit
d96cf68d95
1 changed files with 2 additions and 2 deletions
|
@ -51,8 +51,8 @@ export default function linkify(text) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (result.length === 1 && typeof result[0] === 'string') {
|
if (result.length === 1) {
|
||||||
return text;
|
return result[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue