Diff

Differences From Artifact [5dbcaf75a3]:

To Artifact [e6983d567a]:


   128    128   				 * Register a handler to handle the window being closed without
   129    129   				 * having sent anything
   130    130   				 */
   131    131   				pinWindow.onClosed.addListener(function() {
   132    132   					if (pinWindowDidWork != 1) {
   133    133   						console.log("[cackey] The PIN dialog was closed without resubmitting the request, treating it as a failure");
   134    134   
   135         -						cackeyMessageIncoming(
   136         -							{
   137         -								"data": {
   138         -									"target": "cackey",
   139         -									"command": messageEvent.data.command,
   140         -									"id": messageEvent.data.id,
   141         -									"status": "error",
   142         -									"error": "PIN window closed without a PIN being provided"
   143         -								}
   144         -							}
   145         -						)
          135  +						messageEvent.data.status = "error";
          136  +						messageEvent.data.error = "PIN window closed without a PIN being provided";
   146    137   
          138  +						cackeyMessageIncoming(messageEvent);
   147    139   					}
          140  +
   148    141   					return;
   149    142   				})
   150    143   
   151    144   				/*
   152    145   				 * Pass this message off to the other window so that it may resubmit the request.
   153    146   				 */
   154    147   				pinWindow.contentWindow.parentWindow = window;