Skip to content

Commit

Permalink
some more wip
Browse files Browse the repository at this point in the history
  • Loading branch information
Lms24 committed Sep 18, 2024
1 parent 8285c6f commit 5e2e77a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@ import * as Sentry from '@sentry/sveltekit';

export const load = async ({ url }) => {
if (!url.search) {
console.log('traceData: ', Sentry.getTraceData());
console.log('spanToTrace', Sentry.spanToTraceHeader(Sentry.getActiveSpan()!));
console.log('activeSpan', Sentry.getActiveSpan());
Sentry.captureException(new Error('No search query provided'));
return {
error: 'No search query provided',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
<script lang="ts">
import { onMount } from 'svelte';
import * as Sentry from '@sentry/sveltekit';
export let data;
onMount(() => {
if (data.error) {
console.log(Sentry.getTraceData());
throw new Error('Client Error');
}
});
Expand Down

0 comments on commit 5e2e77a

Please sign in to comment.