Skip to content

Commit

Permalink
fix: unable to edit head of messages with regex
Browse files Browse the repository at this point in the history
  • Loading branch information
mattebit committed Dec 19, 2023
1 parent 88ad2d8 commit a7273b6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tool/src/main/java/migt/HTTPReqRes.java
Original file line number Diff line number Diff line change
Expand Up @@ -651,7 +651,7 @@ public void editHeadParam(boolean isRequest, String param, String new_value) {
* @param new_value the new value to substitute
*/
public void editHeadRegex(boolean isRequest, String regex, String new_value) {
if (!isResponse) {
if (!isRequest && !this.isResponse) {
throw new RuntimeException("tried to edit headers of response not yet received");
}

Expand Down

0 comments on commit a7273b6

Please sign in to comment.