Fixed single name delimiter slicing last letter off all names.
This commit is contained in:
parent
039eb22ae7
commit
a8bd2cb62a
|
@ -33,8 +33,12 @@ async function getWekanActorNames() {
|
|||
const actorNames = wekanBoardRes.body.map((card) => {
|
||||
const name = card.title.split(/\s+/).slice(0, 2).join(' ');
|
||||
|
||||
if (name.includes('.')) {
|
||||
// allow single name to be delimited
|
||||
return name.slice(0, name.indexOf('.'));
|
||||
}
|
||||
|
||||
return name;
|
||||
;});
|
||||
|
||||
return actorNames;
|
||||
|
|
Loading…
Reference in New Issue