(event)
| 130 | } |
| 131 | |
| 132 | function onExamineResponse(event) { |
| 133 | try { |
| 134 | let channel = event.subject.QueryInterface(Ci.nsIHttpChannel); |
| 135 | let tab = tabUtil.getTabForContentWindow(firefox.getWindowForRequest(event.subject)); |
| 136 | let tabIdForRequest = firefox.getIdForTabElement(tab); |
| 137 | if (isChannelInitialDocument(channel)) { |
| 138 | resetInfoForTab(tabIdForRequest); |
| 139 | if (tabs.activeTab.id == tabIdForRequest) { |
| 140 | updateButton(tabInfo.get(tabIdForRequest).vulnerableCount); |
| 141 | } |
| 142 | } |
| 143 | |
| 144 | if (/javascript/.test(channel.getResponseHeader("Content-Type"))) { |
| 145 | let requestedUri = event.subject.URI.spec; |
| 146 | if (repo.dontCheck(requestedUri)) { |
| 147 | return; |
| 148 | } |
| 149 | tabInfo.get(tabIdForRequest).jsSources.push(requestedUri); |
| 150 | } |
| 151 | } catch(e) { |
| 152 | } |
| 153 | return; |
| 154 | } |
| 155 | |
| 156 | resetInfoForTab(tabs.activeTab.id); |
nothing calls this directly
no test coverage detected