Index: /applications/editors/josm/plugins/mapillary/README
===================================================================
--- /applications/editors/josm/plugins/mapillary/README	(revision 31340)
+++ /applications/editors/josm/plugins/mapillary/README	(revision 31341)
@@ -1,6 +1,4 @@
 README 
 ======
-
-Readme for your plugin 
 
     * nokutu <nokutu@openmailbox.org>
@@ -9,2 +7,3 @@
       
     * Feel free to contact me for any bug or suggestion.
+
Index: /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/MapillaryData.java
===================================================================
--- /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/MapillaryData.java	(revision 31340)
+++ /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/MapillaryData.java	(revision 31341)
@@ -13,5 +13,5 @@
 /**
  * Database class for all the MapillaryImage objects.
- * 
+ *
  * @author nokutu
  * @see MapillaryAbstractImage
@@ -46,5 +46,5 @@
     /**
      * Adds a set of MapillaryImages to the object, and then repaints mapView.
-     * 
+     *
      * @param images
      *            The set of images to be added.
@@ -58,5 +58,5 @@
     /**
      * Adds an MapillaryImage to the object, and then repaints mapView.
-     * 
+     *
      * @param image
      *            The image to be added.
@@ -81,5 +81,5 @@
      * Adds a set of MapillaryImages to the object, but doesn't repaint mapView.
      * This is needed for concurrency.
-     * 
+     *
      * @param images
      *            The set of images to be added.
@@ -94,5 +94,5 @@
     /**
      * Highlights the image under the cursor.
-     * 
+     *
      * @param image
      *            The image under the cursor.
@@ -104,5 +104,5 @@
     /**
      * Returns the image under the mouse cursor.
-     * 
+     *
      * @return The image under the mouse cursor.
      */
@@ -114,5 +114,5 @@
      * Adds a MapillaryImage to the object, but doesn't repaint mapView. This is
      * needed for concurrency.
-     * 
+     *
      * @param image
      *            The image to be added.
@@ -135,5 +135,5 @@
     /**
      * Returns a List containing all images.
-     * 
+     *
      * @return A List object containing all images.
      */
@@ -144,5 +144,5 @@
     /**
      * Returns the MapillaryImage object that is currently selected.
-     * 
+     *
      * @return The selected MapillaryImage object.
      */
@@ -215,5 +215,5 @@
      * surrounding thumbnails. If the user does ctrl+click, this isn't
      * triggered.
-     * 
+     *
      * @param image
      *            The MapillaryImage which is going to be selected
@@ -229,5 +229,5 @@
      * triggered. You can choose whether to center the view on the new image or
      * not.
-     * 
+     *
      * @param image
      *            The {@link MapillaryImage} which is going to be selected.
@@ -282,5 +282,5 @@
      * Adds a MapillaryImage object to the list of selected images, (when ctrl +
      * click)
-     * 
+     *
      * @param image
      *            The MapillaryImage object to be added.
@@ -299,5 +299,5 @@
      * Adds a set of {@code MapillaryAbstractImage} objects to the list of
      * selected images.
-     * 
+     *
      * @param images
      *            A List object containing the set of images to be added.
@@ -317,5 +317,5 @@
      * Returns a List containing all {@code MapillaryAbstractImage} objects
      * selected with ctrl + click
-     * 
+     *
      * @return A List object containing all the images selected.
      */
@@ -336,5 +336,5 @@
     /**
      * Returns the amount of images contained by this object.
-     * 
+     *
      * @return The amount of images in stored.
      */
Index: /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/MapillaryImportedImage.java
===================================================================
--- /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/MapillaryImportedImage.java	(revision 31340)
+++ /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/MapillaryImportedImage.java	(revision 31341)
@@ -32,6 +32,7 @@
      * Returns the pictures of the file.
      * 
-     * @return
+     * @return An BufferedImage object containing the pictures.
      * @throws IOException
+     * @throws IllegalArgumentException if file is currently set to null 
      */
     public BufferedImage getImage() throws IOException {
Index: /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/MapillaryLayer.java
===================================================================
--- /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/MapillaryLayer.java	(revision 31340)
+++ /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/MapillaryLayer.java	(revision 31341)
@@ -166,5 +166,5 @@
      * Returns the MapillaryData object, which acts as the database of the
      * Layer.
-     * 
+     *
      * @return
      */
@@ -214,5 +214,5 @@
     /**
      * Replies background color for downloaded areas.
-     * 
+     *
      * @return background color for downloaded areas. Black by default
      */
@@ -223,5 +223,5 @@
     /**
      * Replies background color for non-downloaded areas.
-     * 
+     *
      * @return background color for non-downloaded areas. Yellow by default
      */
@@ -349,5 +349,5 @@
     /**
      * Draws the highlight of the icon.
-     * 
+     *
      * @param g
      * @param p
@@ -372,5 +372,5 @@
      * Draws the given icon of an image. Also checks if the mouse is over the
      * image.
-     * 
+     *
      * @param g
      * @param image
@@ -428,5 +428,5 @@
     /**
      * Returns the 2 closest images belonging to a different sequence.
-     * 
+     *
      * @return
      */
@@ -504,5 +504,5 @@
      * When more data is downloaded, a delayed update is thrown, in order to
      * wait for the data bounds to be set.
-     * 
+     *
      * @param event
      */
Index: /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/actions/MapillaryDownloadViewAction.java
===================================================================
--- /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/actions/MapillaryDownloadViewAction.java	(revision 31340)
+++ /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/actions/MapillaryDownloadViewAction.java	(revision 31341)
@@ -17,5 +17,5 @@
 /**
  * If in manual mode, downloads all the images in the current view.
- * 
+ *
  * @author nokutu
  *
@@ -23,5 +23,5 @@
 public class MapillaryDownloadViewAction extends JosmAction {
 
-    public static double MAX_AREA = Main.pref.getDouble(
+    public static final double MAX_AREA = Main.pref.getDouble(
             "mapillary.max-download-area", 0.020);
 
Index: /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/downloads/MapillaryImageInfoDownloaderThread.java
===================================================================
--- /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/downloads/MapillaryImageInfoDownloaderThread.java	(revision 31340)
+++ /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/downloads/MapillaryImageInfoDownloaderThread.java	(revision 31341)
@@ -20,5 +20,5 @@
 /**
  * This thread downloads one of the images in a given area.
- * 
+ *
  * @author nokutu
  * @see MapillarySquareDownloadManagerThread
@@ -39,5 +39,5 @@
         try {
             BufferedReader br = new BufferedReader(new InputStreamReader(
-                    new URL(url).openStream()));
+                    new URL(url).openStream(), "UTF-8"));
             JsonObject jsonobj = Json.createReader(br).readObject();
             if (!jsonobj.getBoolean("more"))
Index: /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/downloads/MapillarySequenceDownloadThread.java
===================================================================
--- /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/downloads/MapillarySequenceDownloadThread.java	(revision 31340)
+++ /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/downloads/MapillarySequenceDownloadThread.java	(revision 31341)
@@ -25,5 +25,5 @@
  * needed MapillaryImage and MapillarySequence objects. It just stores the ones
  * in the given area.
- * 
+ *
  * @author nokutu
  * @see MapillarySquareDownloadManagerThread
@@ -50,5 +50,5 @@
             BufferedReader br;
             br = new BufferedReader(new InputStreamReader(
-                    new URL(url).openStream()));
+                    new URL(url).openStream(), "UTF-8"));
             JsonObject jsonall = Json.createReader(br).readObject();
 
Index: /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/downloads/MapillarySignDownloaderThread.java
===================================================================
--- /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/downloads/MapillarySignDownloaderThread.java	(revision 31340)
+++ /applications/editors/josm/plugins/mapillary/src/org/openstreetmap/josm/plugins/mapillary/downloads/MapillarySignDownloaderThread.java	(revision 31341)
@@ -35,5 +35,5 @@
         try {
             br = new BufferedReader(new InputStreamReader(
-                    new URL(url).openStream()));
+                    new URL(url).openStream(), "UTF-8"));
             JsonObject jsonobj = Json.createReader(br).readObject();
             if (!jsonobj.getBoolean("more")) {
Index: /applications/editors/josm/plugins/mapillary/test/unit/org/openstreetmap/josm/plugins/mapillary/ImportTest.java
===================================================================
--- /applications/editors/josm/plugins/mapillary/test/unit/org/openstreetmap/josm/plugins/mapillary/ImportTest.java	(revision 31340)
+++ /applications/editors/josm/plugins/mapillary/test/unit/org/openstreetmap/josm/plugins/mapillary/ImportTest.java	(revision 31341)
@@ -2,4 +2,6 @@
 
 import static org.junit.Assert.*;
+
+import java.io.IOException;
 
 import org.junit.Before;
@@ -14,9 +16,10 @@
 	}
 	
-	@Test
-	public void test() {
-		MapillaryImportedImage img = new MapillaryImportedImage(0,0,0, null);
-		assert(true);
-	}
+
+    @Test(expected=IllegalArgumentException.class)
+    public void test() throws IOException {
+        MapillaryImportedImage img = new MapillaryImportedImage(0,0,0, null);
+        img.getImage();
+    }
 
 }
