Changeset 17606 in josm for trunk/src/org


Ignore:
Timestamp:
2021-03-20T21:20:17+01:00 (4 years ago)
Author:
simon04
Message:

TaggingPreset: use SequenceCommand.wrapIfNeeded

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/tagging/presets/TaggingPreset.java

    r17031 r17606  
    562562                .filter(cmd -> cmd.getObjectsNumber() > 0)
    563563                .collect(StreamUtils.toUnmodifiableList());
    564 
    565         if (cmds.isEmpty())
    566             return null;
    567         else if (cmds.size() == 1)
    568             return cmds.get(0);
    569         else
    570             return new SequenceCommand(tr("Change Tags"), cmds);
     564        return cmds.isEmpty() ? null : SequenceCommand.wrapIfNeeded(tr("Change Tags"), cmds);
    571565    }
    572566
Note: See TracChangeset for help on using the changeset viewer.