Skip to content

Commit

Permalink
Check for null postData
Browse files Browse the repository at this point in the history
Closes #279
  • Loading branch information
MisterPhilip committed Jan 2, 2025
1 parent 35c0bd3 commit 0e325c2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/serviceWorker.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ chrome.webRequest.onBeforeRequest.addListener(
};

// Grab any POST data that is included
if (details.method === "POST" && typeof details.requestBody !== "undefined") {
if (details.method === "POST" && typeof details.requestBody !== "undefined" && details.requestBody) {
const body = details.requestBody;
if(typeof body.error !== "undefined" && body.error) {
data.request.postError = true;
Expand Down

0 comments on commit 0e325c2

Please sign in to comment.