graphql-http 1.22.2 → 1.22.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/handler.js CHANGED
@@ -19,9 +19,9 @@ function isResponse(val) {
19
19
  return false;
20
20
  // Make sure the contents of init match ResponseInit
21
21
  const init = val[1];
22
- if (typeof init.status !== 'number')
22
+ if (init.status && typeof init.status !== 'number')
23
23
  return false;
24
- if (typeof init.statusText !== 'string')
24
+ if (init.statusText && typeof init.statusText !== 'string')
25
25
  return false;
26
26
  if (init.headers && !(0, utils_1.isObject)(init.headers))
27
27
  return false;
package/lib/handler.mjs CHANGED
@@ -16,9 +16,9 @@ function isResponse(val) {
16
16
  return false;
17
17
  // Make sure the contents of init match ResponseInit
18
18
  const init = val[1];
19
- if (typeof init.status !== 'number')
19
+ if (init.status && typeof init.status !== 'number')
20
20
  return false;
21
- if (typeof init.statusText !== 'string')
21
+ if (init.statusText && typeof init.statusText !== 'string')
22
22
  return false;
23
23
  if (init.headers && !isObject(init.headers))
24
24
  return false;
@@ -1,4 +1,4 @@
1
- import { HandlerOptions as RawHandlerOptions, OperationContext } from '../../handler.mjs';
1
+ import { HandlerOptions as RawHandlerOptions, OperationContext } from '../../handler/index.mjs';
2
2
  import type { Handler as NetlifyHandler, HandlerEvent as NetlifyHandlerEvent, HandlerContext as NetlifyHandlerContext } from '@netlify/functions';
3
3
  /**
4
4
  * Handler options when using the netlify adapter
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "graphql-http",
3
- "version": "1.22.2",
3
+ "version": "1.22.3",
4
4
  "description": "Simple, pluggable, zero-dependency, GraphQL over HTTP spec compliant server, client and audit suite.",
5
5
  "keywords": [
6
6
  "graphql",