Compare commits

...
2 Commits
Author SHA1 Message Date
DebaucheryLibrarian 1402f28b98 1.1.2 2023-12-05 23:37:00 +01:00
DebaucheryLibrarian 02cd395ff5 Handling missing card titles. 2023-12-05 23:36:59 +01:00
6 changed files with 11 additions and 5 deletions
Regular → Executable
View File
Regular → Executable
View File
Regular → Executable
View File
Generated Regular → Executable
+2 -2
View File
@@ -1,12 +1,12 @@
{ {
"name": "kanbanmod", "name": "kanbanmod",
"version": "1.1.1", "version": "1.1.2",
"lockfileVersion": 2, "lockfileVersion": 2,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "kanbanmod", "name": "kanbanmod",
"version": "1.1.1", "version": "1.1.2",
"license": "ISC", "license": "ISC",
"dependencies": { "dependencies": {
"bhttp": "^1.2.8", "bhttp": "^1.2.8",
Regular → Executable
+1 -1
View File
@@ -1,6 +1,6 @@
{ {
"name": "kanbanmod", "name": "kanbanmod",
"version": "1.1.1", "version": "1.1.2",
"description": "", "description": "",
"main": "index.js", "main": "index.js",
"scripts": { "scripts": {
Regular → Executable
+7 -1
View File
@@ -31,6 +31,12 @@ async function getWekanActorNames() {
} }
const actorNames = wekanBoardRes.body.map((card) => { const actorNames = wekanBoardRes.body.map((card) => {
if (!card.title) {
console.warn('Missing card title', card);
return null;
}
const name = card.title.split(/\s+/).slice(0, 2).join(' '); const name = card.title.split(/\s+/).slice(0, 2).join(' ');
if (name.includes('.')) { if (name.includes('.')) {
@@ -41,7 +47,7 @@ async function getWekanActorNames() {
return name; return name;
;}); ;});
return actorNames; return actorNames.filter(Boolean);
} }
async function init() { async function init() {