summaryrefslogtreecommitdiff
path: root/packages/integrations/preact/server.js
diff options
context:
space:
mode:
authorGravatar hippotastic <hippotastic@users.noreply.github.com> 2022-06-30 12:12:27 +0000
committerGravatar fredkbot <fred+astrobot@astro.build> 2022-06-30 12:12:27 +0000
commit40fa87c2744b28929f529e5457d9b3949ec53a59 (patch)
tree7cfe78fb53a837c731a554418e7e9860877c5bce /packages/integrations/preact/server.js
parentb934ab5d860aa3adeec56a9c395f629ee7252ca4 (diff)
downloadastro-40fa87c2744b28929f529e5457d9b3949ec53a59.tar.gz
astro-40fa87c2744b28929f529e5457d9b3949ec53a59.tar.zst
astro-40fa87c2744b28929f529e5457d9b3949ec53a59.zip
[ci] format
Diffstat (limited to 'packages/integrations/preact/server.js')
-rw-r--r--packages/integrations/preact/server.js9
1 files changed, 4 insertions, 5 deletions
diff --git a/packages/integrations/preact/server.js b/packages/integrations/preact/server.js
index 36f66b7b5..f5b1a34e5 100644
--- a/packages/integrations/preact/server.js
+++ b/packages/integrations/preact/server.js
@@ -51,9 +51,9 @@ function renderToStaticMarkup(Component, props, { default: children, ...slotted
/**
* Reduces console noise by filtering known non-problematic errors.
- *
+ *
* Performs reference counting to allow parallel usage from async code.
- *
+ *
* To stop filtering, please ensure that there always is a matching call
* to `finishUsingConsoleFilter` afterwards.
*/
@@ -87,7 +87,7 @@ function finishUsingConsoleFilter() {
/**
* Hook/wrapper function for the global `console.error` function.
- *
+ *
* Ignores known non-problematic errors while any code is using the console filter.
* Otherwise, simply forwards all arguments to the original function.
*/
@@ -99,8 +99,7 @@ function filteredConsoleError(msg, ...rest) {
const isKnownReactHookError =
msg.includes('Warning: Invalid hook call.') &&
msg.includes('https://reactjs.org/link/invalid-hook-call');
- if (isKnownReactHookError)
- return;
+ if (isKnownReactHookError) return;
}
originalConsoleError(msg, ...rest);
}