Index: applications/editors/josm/plugins/DirectUpload/src/org/openstreetmap/josm/plugins/DirectUpload/UploadDataGui.java
===================================================================
--- applications/editors/josm/plugins/DirectUpload/src/org/openstreetmap/josm/plugins/DirectUpload/UploadDataGui.java	(revision 30532)
+++ applications/editors/josm/plugins/DirectUpload/src/org/openstreetmap/josm/plugins/DirectUpload/UploadDataGui.java	(revision 30737)
@@ -52,5 +52,5 @@
  */
 public class UploadDataGui extends ExtendedDialog {
-    
+
     /**
      * This enum contains the possible values for the visibility field and their
@@ -103,5 +103,5 @@
 
     private boolean canceled = false;
-    
+
     public UploadDataGui() {
         // Initalizes ExtendedDialog
@@ -113,5 +113,5 @@
         JPanel content = initComponents();
         GpxData gpxData = UploadOsmConnection.getInstance().autoSelectTrace();
-        initTitleAndDescriptionFromGpxData(gpxData);    // this is changing some dialog elements, so it (probably) must be before the following  
+        initTitleAndDescriptionFromGpxData(gpxData);    // this is changing some dialog elements, so it (probably) must be before the following
         setContent(content);
         setButtonIcons(new String[] { "uploadtrace.png", "cancel.png" });
@@ -129,5 +129,5 @@
         JLabel visibilityLabel = new JLabel(tr("Visibility"));
         visibilityLabel.setToolTipText(tr("Defines the visibility of your trace for other OSM users."));
-        
+
         visibilityCombo = new JComboBox<>();
         visibilityCombo.setEditable(false);
@@ -142,6 +142,6 @@
         descriptionField = new HistoryComboBox();
         descriptionField.setToolTipText(tr("Please enter Description about your trace."));
-        
-        List<String> descHistory = new LinkedList<String>(Main.pref.getCollection("directupload.description.history", new LinkedList<String>()));
+
+        List<String> descHistory = new LinkedList<>(Main.pref.getCollection("directupload.description.history", new LinkedList<String>()));
         // we have to reverse the history, because ComboBoxHistory will reverse it again in addElement()
         // XXX this should be handled in HistoryComboBox
@@ -154,5 +154,5 @@
         tagsField.setToolTipText(tr("Please enter tags about your trace."));
 
-        List<String> tagsHistory = new LinkedList<String>(Main.pref.getCollection("directupload.tags.history", new LinkedList<String>()));
+        List<String> tagsHistory = new LinkedList<>(Main.pref.getCollection("directupload.tags.history", new LinkedList<String>()));
         // we have to reverse the history, because ComboBoxHistory will reverse it againin addElement()
         // XXX this should be handled in HistoryComboBox
@@ -199,5 +199,5 @@
       }
       else {
-          description = new SimpleDateFormat("yyMMddHHmmss").format(new Date()); 
+          description = new SimpleDateFormat("yyMMddHHmmss").format(new Date());
           title = tr("No GPX layer selected. Cannot upload a trace.");
       }
@@ -296,6 +296,6 @@
         c.setRequestMethod("POST");
         c.setDoOutput(true);
-        // unfortunately, addAuth() is protected, so we need to subclass OsmConnection 
-        // XXX make addAuth public. 
+        // unfortunately, addAuth() is protected, so we need to subclass OsmConnection
+        // XXX make addAuth public.
         UploadOsmConnection.getInstance().addAuthHack(c);
 
@@ -322,5 +322,5 @@
                 returnMsg += "\n" + c.getHeaderField("Error");
         }
-        
+
         final String returnMsgEDT = returnMsg;
 
@@ -408,5 +408,5 @@
 
         final String errorsEDT = errors;
-        
+
         GuiHelper.runInEDT(new Runnable() {
             @Override public void run() {
@@ -414,5 +414,5 @@
             }
         });
-        
+
         return errors.length() > 0;
     }
@@ -429,8 +429,8 @@
         // Disable Upload button so users can't just upload that track again
         buttons.get(0).setEnabled(false);
-        
+
         // save history
         Main.pref.put("directupload.visibility.last-used", visibility.desc2visi(visibilityCombo.getSelectedItem().toString()).name());
-        
+
         descriptionField.addCurrentItemToHistory();
         Main.pref.putCollection("directupload.description.history", descriptionField.getHistory());
