Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ui/src/workflow/common/data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -130,8 +130,8 @@ export const knowledgeWriteNode = {
type: WorkflowType.KnowledgeWriteNode,
text: t('views.workflow.nodes.knowledgeWriteNode.text'),
label: t('views.workflow.nodes.knowledgeWriteNode.label'),
height: 252,
properties: {
height: 252,
stepName: t('views.workflow.nodes.knowledgeWriteNode.label'),
config: {
fields: [],
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code appears to be a function definition within an object called knowledgeWriteNode. There is a slight issue with the height property being set twice, which is unnecessary and potentially redundant.

Here's a revised version of the code:

export const knowledgeWriteNode = {
  type: WorkflowType.KnowledgeWriteNode,
  text: t('views.workflow.nodes.knowledgeWriteNode.text'),
  label: t('views.workflow.nodes.knowledgeWriteNode.label'),
+  height: 252,
  properties: {
    // Remove the duplicate 'height' field here if it's not intentionally repeated elsewhere in your codebase
    stepName: t('views.workflow.nodes.knowledgeWriteNode.label'),
    config: {
      fields: [],
    },
};

This change ensures that each key-value pair in the properties object is unique and reduces redundancy. If you have other instances where the height might also appear incorrectly in the same context, those should also be addressed accordingly.

Expand Down
Loading