mirror of
https://git.mirrors.martin98.com/https://github.com/cilame/v_jstools
synced 2025-08-14 05:15:55 +08:00
add
This commit is contained in:
parent
304873cb8b
commit
dff299ba2e
@ -42,7 +42,7 @@ chrome.debugger.onEvent.addListener(function (source, method, params){
|
|||||||
if (params.resourceType == 'Document'){ var replbody = btoa(unescape(encodeURIComponent(html_script_replacer(respboby, replacer, params.request.url)))) }
|
if (params.resourceType == 'Document'){ var replbody = btoa(unescape(encodeURIComponent(html_script_replacer(respboby, replacer, params.request.url)))) }
|
||||||
fillfunc(replbody) }
|
fillfunc(replbody) }
|
||||||
catch(e){
|
catch(e){
|
||||||
send_error_info_to_front(e.stack, currtab.tabId)
|
send_error_info_to_front(e.stack, currtab.tabId, params.request.url)
|
||||||
fillfunc(result.body) }
|
fillfunc(result.body) }
|
||||||
})
|
})
|
||||||
return }
|
return }
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
function send_error_info_to_front(e, tid){
|
function send_error_info_to_front(e, tid, url){
|
||||||
chrome.tabs.query({active: true, currentWindow: true}, function(tabs){
|
chrome.tabs.query({active: true, currentWindow: true}, function(tabs){
|
||||||
chrome.tabs.sendMessage(tid, {action: {type:'error', info: e}}, function(response) {});
|
chrome.tabs.sendMessage(tid, {action: {type:'error', info: url + '\n' + e}}, function(response) {});
|
||||||
});
|
});
|
||||||
}
|
}
|
Loading…
x
Reference in New Issue
Block a user