]> git.feebdaed.xyz Git - lgtm-rsvp.git/commitdiff
fix: get comment by id query
authorseantywork <seantywork@gmail.com>
Sun, 27 Jul 2025 05:10:54 +0000 (05:10 +0000)
committerseantywork <seantywork@gmail.com>
Sun, 27 Jul 2025 05:11:06 +0000 (05:11 +0000)
pkg/db/db_comment.go

index d9ad21679b4348ce89d19eaed0d58dfa16e1070b..58640a3e72ac013b06a92d20e5985390eb32165d 100644 (file)
@@ -75,6 +75,7 @@ func GetCommentById(id string) (*Comment, error) {
        q := `
        
        SELECT
+               id,
                title,
                content,
                timestamp_registered
@@ -105,6 +106,7 @@ func GetCommentById(id string) (*Comment, error) {
                comment := Comment{}
 
                err = res.Scan(
+                       &comment.Id,
                        &comment.Title,
                        &comment.Content,
                        &comment.TimestampRegistered,