mirror of
https://github.com/vee1e/mitmproxy.git
synced 2026-09-01 18:27:18 +00:00
Fix crash when using body filters (#2744)
fix crash when using body filters They still don't work, but at least the web interface won't crash.
This commit is contained in:
parent
68c32d8627
commit
828e1a87ca
2 changed files with 7 additions and 7 deletions
|
|
@ -1929,7 +1929,7 @@ module.exports = (function() {
|
|||
function body(regex){
|
||||
regex = new RegExp(regex, "i");
|
||||
function bodyFilter(flow){
|
||||
return True;
|
||||
return true;
|
||||
}
|
||||
bodyFilter.desc = "body filters are not implemented yet, see https://github.com/mitmproxy/mitmweb/issues/10";
|
||||
return bodyFilter;
|
||||
|
|
@ -1937,7 +1937,7 @@ module.exports = (function() {
|
|||
function requestBody(regex){
|
||||
regex = new RegExp(regex, "i");
|
||||
function requestBodyFilter(flow){
|
||||
return True;
|
||||
return true;
|
||||
}
|
||||
requestBodyFilter.desc = "body filters are not implemented yet, see https://github.com/mitmproxy/mitmweb/issues/10";
|
||||
return requestBodyFilter;
|
||||
|
|
@ -1945,7 +1945,7 @@ module.exports = (function() {
|
|||
function responseBody(regex){
|
||||
regex = new RegExp(regex, "i");
|
||||
function responseBodyFilter(flow){
|
||||
return True;
|
||||
return true;
|
||||
}
|
||||
responseBodyFilter.desc = "body filters are not implemented yet, see https://github.com/mitmproxy/mitmweb/issues/10";
|
||||
return responseBodyFilter;
|
||||
|
|
@ -2104,4 +2104,4 @@ module.exports = (function() {
|
|||
SyntaxError: peg$SyntaxError,
|
||||
parse: peg$parse
|
||||
};
|
||||
})();
|
||||
})();
|
||||
|
|
|
|||
|
|
@ -72,7 +72,7 @@ function responseCode(code){
|
|||
function body(regex){
|
||||
regex = new RegExp(regex, "i");
|
||||
function bodyFilter(flow){
|
||||
return True;
|
||||
return true;
|
||||
}
|
||||
bodyFilter.desc = "body filters are not implemented yet, see https://github.com/mitmproxy/mitmweb/issues/10";
|
||||
return bodyFilter;
|
||||
|
|
@ -80,7 +80,7 @@ function body(regex){
|
|||
function requestBody(regex){
|
||||
regex = new RegExp(regex, "i");
|
||||
function requestBodyFilter(flow){
|
||||
return True;
|
||||
return true;
|
||||
}
|
||||
requestBodyFilter.desc = "body filters are not implemented yet, see https://github.com/mitmproxy/mitmweb/issues/10";
|
||||
return requestBodyFilter;
|
||||
|
|
@ -88,7 +88,7 @@ function requestBody(regex){
|
|||
function responseBody(regex){
|
||||
regex = new RegExp(regex, "i");
|
||||
function responseBodyFilter(flow){
|
||||
return True;
|
||||
return true;
|
||||
}
|
||||
responseBodyFilter.desc = "body filters are not implemented yet, see https://github.com/mitmproxy/mitmweb/issues/10";
|
||||
return responseBodyFilter;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue