mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-18 02:21:13 +00:00
🐛 Fix issue listing databases without name on Notion Node (#2197)
This commit is contained in:
@@ -100,7 +100,7 @@ export class NotionTrigger implements INodeType {
|
|||||||
const { results: databases } = await notionApiRequest.call(this, 'POST', `/search`, { page_size: 100, filter: { property: 'object', value: 'database' } });
|
const { results: databases } = await notionApiRequest.call(this, 'POST', `/search`, { page_size: 100, filter: { property: 'object', value: 'database' } });
|
||||||
for (const database of databases) {
|
for (const database of databases) {
|
||||||
returnData.push({
|
returnData.push({
|
||||||
name: database.title[0].plain_text,
|
name: database.title[0]?.plain_text || database.id,
|
||||||
value: database.id,
|
value: database.id,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user