Skip to content

Commit 3c6a7f2

Browse files
committed
chore: clarify comments
1 parent 27092ae commit 3c6a7f2

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

internal/libs/db/db.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ func NewDB(cfg *cfg.Cfg, logger *logger.Logger) (*DB, error) {
5454
func (db *DB) ensureIndexes() {
5555
sessions := db.Database("paperdebugger").Collection((models.LLMSession{}).CollectionName())
5656

57-
// TTL index: auto-delete sessions after 30 days
57+
// TTL index: auto-delete sessions after 30 days past their expiry time
5858
_, err := sessions.Indexes().CreateOne(context.Background(), mongo.IndexModel{
5959
Keys: bson.D{{Key: "session_expiry", Value: 1}},
6060
Options: options.Index().SetExpireAfterSeconds(30 * 24 * 60 * 60),

0 commit comments

Comments
 (0)