### Eclipse Workspace Patch 1.0
#P JMapViewer
Index: src/org/openstreetmap/gui/jmapviewer/tilesources/BingAerialTileSource.java
===================================================================
--- src/org/openstreetmap/gui/jmapviewer/tilesources/BingAerialTileSource.java	(revision 36495)
+++ src/org/openstreetmap/gui/jmapviewer/tilesources/BingAerialTileSource.java	(working copy)
@@ -102,9 +103,10 @@
 
     @Override
     public String getTileUrl(int zoom, int tilex, int tiley) throws IOException {
-        // make sure that attribution is loaded. otherwise subdomains is null.
-        if (getAttribution() == null)
-            throw new IOException("Attribution is not loaded yet");
+        // Fail-fast with a clear message
+        if (getAttribution() == null || subdomains == null || subdomains.length == 0) {
+            throw new IOException("Attribution or subdomains not initialized");
+        }
 
         int t = (zoom + tilex + tiley) % subdomains.length;
         String subdomain = subdomains[t];

