Opened 7 years ago

Closed 2 years ago

#4554 closed defect (fixed)

remove trailing whitespace in tags

Reported by: Cobra Owned by: potlatch-dev@…
Priority: minor Milestone:
Component: potlatch2 Version:
Keywords: Cc: scai

Description

Potlatch2 doesn't remove trailing whitespace in tags. For example v2 of node 1864014640 has a broken name tag:

<tag k="name " v="Hopfgarten"/>

I can't see any point in keeping trailing whitespace, it should be discarded automatically.

josm removes trailing whitespace for keys and values.

Change History (4)

comment:1 Changed 7 years ago by scai

Cc: scai added

comment:2 Changed 4 years ago by art.penteur@…

I confirm I've noticed results from this bug, and I would really apreciate it to be corrected.

I Run a robot once in while on french highway names to remove trailing whitespaces, and I don't believe it is an apropriate solution.

Thanks for taking care of this.

comment:3 Changed 4 years ago by Richard

There's three possible ways you could solve this if you were so minded:

  1. Alter the TagGrid?'s raw input component to remove trailing spaces. This would be the best but probably the hardest.
  2. Alter tagChanged in TagGrid?.mxml. I think this should be relatively easy and is probably the most realistic approach.
  3. Alter the serialisation logic when saving. This would be a bit hacky, please don't do this.

But you should be able to fix it fairly easily.

comment:4 Changed 2 years ago by Richard

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.