Skip to content
This repository was archived by the owner on Mar 19, 2025. It is now read-only.
This repository was archived by the owner on Mar 19, 2025. It is now read-only.

TagsConverter creates an empty tag when the input is blank #469

@czarnecki

Description

@czarnecki

TagsConverter simply calls String#split(String) which creates an array which only contains the empty string when the input is empty.
That data is then simply passed along further with no validation anywhere.
Because of this that empty string gets saved in the database.
As a work around EditBudgetForm removes the first element of the tags list, if it's not empty.
This means the following steps are necessary to remedy the error:

  • Fix TagsConverter to properly handle empty input
  • Create a migration that removes the invalid data
  • Remove the work around from EditBudgetForm

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions