Clears selection rectangle that was just sort of hanging out
diff --git a/asterix-examples/src/main/resources/black-cherry/static/js/cherry.js b/asterix-examples/src/main/resources/black-cherry/static/js/cherry.js
index ad92e79..5e28dbd 100755
--- a/asterix-examples/src/main/resources/black-cherry/static/js/cherry.js
+++ b/asterix-examples/src/main/resources/black-cherry/static/js/cherry.js
@@ -230,27 +230,30 @@
 		
 		if ($('#asbox').is(":checked")) {
 		    build_cherry_mode = "asynchronous";
+		    $('#show-query-button').attr("disabled", false);
+		} else {
+		    $('#show-query-button').attr("disabled", true);
 		}
 	
         var f = buildAQLQueryFromForm(formData);
         
+        APIqueryTracker = {
+		    "query" : "use dataverse twitter;\n" + f.val(),
+		    "data" : formData
+		};
+		
+		$('#dialog').html(APIqueryTracker["query"]);
+        
         if (build_cherry_mode == "synchronous") {
             A.query(f.val(), cherryQuerySyncCallback, build_cherry_mode);
         } else {
             A.query(f.val(), cherryQueryAsyncCallback, build_cherry_mode);
         }
     
-		APIqueryTracker = {
-		    "query" : "use dataverse twitter;\n" + f.val(),
-		    "data" : formData
-		};
-		
-		$('#dialog').html(APIqueryTracker["query"]);
-
-        if (!$('#asbox').is(":checked")) {
-		    $('#show-query-button').attr("disabled", false);
-        } else {
-            $('#show-query-button').attr("disabled", true);
+        // Clears selection rectangle on query execution, rather than waiting for another clear call.
+        if (selectionRect) {
+            selectionRect.setMap(null);
+            selectionRect = null;
         }
     });
 });