Skip to content

Commit cdc13dc

Browse files
committed
Also delete stream_markers related to the deleted videos
1 parent 8c24ee0 commit cdc13dc

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

internal/database/videos.go

+1
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,7 @@ func (q *Query) InsertVideo(v Video) error {
129129

130130
func (q *Query) DeleteVideo(id string) error {
131131
tx := q.DB.MustBegin()
132+
tx.MustExec("delete from stream_markers where video_id=$1", id)
132133
tx.MustExec("delete from video_muted_segments where video_id=$1", id)
133134
tx.MustExec("delete from videos where id = $1", id)
134135
return tx.Commit()

0 commit comments

Comments
 (0)