Skip to content

Conversation

@maryhipp
Copy link
Contributor

@maryhipp maryhipp commented Jan 24, 2024

What type of PR is this? (check all applicable)

  • Refactor
  • Feature
  • Bug Fix
  • Optimization
  • Documentation Update
  • Community Node Submission

Have you discussed this change with the InvokeAI team?

  • Yes
  • No, because:

Have you updated all relevant documentation?

  • Yes
  • No

Description

Related Tickets & Documents

closes #5534

  • Related Issue #
  • Closes #

QA Instructions, Screenshots, Recordings

Merge Plan

Added/updated tests?

  • Yes
  • No : please replace this line with details on why tests
    have not been included

[optional] Are there any post deployment tasks we need to perform?

@psychedelicious
Copy link
Contributor

What specifically does this fix and why does it fix it? Are you sure this doesn't break anything else? For example, default workflows shouldn't retain the ID when loaded.

@maryhipp
Copy link
Contributor Author

The problem this is fixing is that on main right now, clicking "save workflow" on a loaded saved workflow creates a new entry instead of updating the existing one.

The id of the workflow was being stripped out here, so the logic to in useSaveWorkflow was always creating a new entry instead of updating the existing one. Default workflows have the id set to undefined in validateWorkflow so shouldn't be impacted by this

@psychedelicious
Copy link
Contributor

Thanks, makes sense.

@maryhipp maryhipp merged commit e59954f into main Jan 24, 2024
@maryhipp maryhipp deleted the maryhipp/fix-workflow-updating branch January 24, 2024 21:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[bug]: "Save Workflow" button in workflow editor saves new copy of workflow instead of updating existing workflow

3 participants