Skip to content

Commit f82cc6c

Browse files
committed
Removed logs, fixed reload of comments.
1 parent 063ee2a commit f82cc6c

File tree

3 files changed

+3
-12
lines changed

3 files changed

+3
-12
lines changed

src/database/Organization.ts

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -661,21 +661,14 @@ class Organization {
661661
// If we succeeded, update the list of comments for the table.
662662
if (commentID) {
663663
const newComments = [...comments, commentID];
664-
const { data: row, error: updateError } = await this.supabase
664+
const { error: updateError } = await this.supabase
665665
.from(table)
666666
.update({ comments: newComments })
667667
.eq('id', id);
668668
if (updateError) return updateError;
669669

670-
// If we succeeded, notify the organization of the change.
671-
if (row) {
672-
if (table === 'suggestions') {
673-
console.log('Notifying of changes');
674-
this.notify(orgid);
675-
} else console.log('Not notifying, not changes comment');
676-
}
677-
678-
console.log('Added comment');
670+
// If we succeeded, notify the organization of the change, since it's
671+
this.notify(orgid);
679672
}
680673
return null;
681674
}

src/routes/org/[orgid]/+layout.svelte

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,6 @@
5555
// When realtime reports revised data, and we aren't navigating, reload all data and render accordingly.
5656
function updateOrg() {
5757
if (navigating.to === null) {
58-
console.log('Invalidating load to refresh data.');
5958
invalidateAll();
6059
}
6160
}

src/routes/org/[orgid]/change/[changeid]/+page.svelte

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,6 @@
6666
// When change changes, reload the comments. undefined = loading, null = error.
6767
let comments = $state<undefined | null | CommentRow[]>(undefined);
6868
$effect(() => {
69-
console.log('Reloading comments');
7069
loadComments(change.comments).then((newComments) => (comments = newComments));
7170
});
7271

0 commit comments

Comments
 (0)