fixed drupal connector (#3893)
https://github.com/Mintplex-Labs/anything-llm/issues/3875#issuecomment-2913211343
This commit is contained in:
parent
245a5969b8
commit
dc80d3e535
@ -180,10 +180,6 @@ class DrupalWiki {
|
||||
// show up (deduplication).
|
||||
const targetUUID = `${hostname}.${page.spaceId}.${page.id}.${page.created}`;
|
||||
const wordCount = page.processedBody.split(" ").length;
|
||||
const tokenCount =
|
||||
page.processedBody.length > 0
|
||||
? tokenizeString(page.processedBody).length
|
||||
: 0;
|
||||
const data = {
|
||||
id: targetUUID,
|
||||
url: `drupalwiki://${page.url}`,
|
||||
@ -195,7 +191,7 @@ class DrupalWiki {
|
||||
published: new Date().toLocaleString(),
|
||||
wordCount: wordCount,
|
||||
pageContent: page.processedBody,
|
||||
token_count_estimate: tokenCount,
|
||||
token_count_estimate: tokenizeString(page.processedBody),
|
||||
};
|
||||
|
||||
const fileName = sanitizeFileName(`${slugify(page.title)}-${data.id}`);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user