Rename backend code references: Bookmann → Bookhoard

Backend changes:
- Update import paths: bookmann/internal → bookhoard/internal
- Rename struct fields: BookmannUUID → BookhoardUUID
- Update handler function names: mapContentIdToBookmannUUID → mapContentIdToBookhoardUUID
- Update HTTP response headers: X-Bookmann-* → X-Bookhoard-*
- Update service and middleware references
- Update main.go imports and references

This is part 2 of the project rename to Bookhoard.
This commit is contained in:
2026-02-01 16:11:54 -05:00
parent d43e0105eb
commit 00a083b60b
38 changed files with 109 additions and 109 deletions
+5 -5
View File
@@ -1,8 +1,8 @@
package handlers
import (
"bookmann/internal/database"
"bookmann/internal/services"
"bookhoard/internal/database"
"bookhoard/internal/services"
"fmt"
"net/http"
"strconv"
@@ -294,7 +294,7 @@ func (h *Handler) AutoLinkBooks(c echo.Context) error {
bestMatch := match.Matches[0]
_, err := h.db.CreateDeviceFileAlias(ctx, database.CreateDeviceFileAliasParams{
MediaItemID: pgtype.UUID{Bytes: bestMatch.BookmannUUID, Valid: true},
MediaItemID: pgtype.UUID{Bytes: bestMatch.BookhoardUUID, Valid: true},
DeviceID: book.DeviceID,
FilePath: book.FilePath.String,
FileSha256: pgtype.Text{String: "", Valid: false},
@@ -304,14 +304,14 @@ func (h *Handler) AutoLinkBooks(c echo.Context) error {
if err == nil {
h.db.LinkUnlinkedBook(ctx, database.LinkUnlinkedBookParams{
ID: book.ID,
MediaItemID: pgtype.UUID{Bytes: bestMatch.BookmannUUID, Valid: true},
MediaItemID: pgtype.UUID{Bytes: bestMatch.BookhoardUUID, Valid: true},
ConfidenceScore: toFloat8(bestMatch.Confidence),
})
results = append(results, map[string]interface{}{
"unlinked_book_id": uuid.UUID(book.ID.Bytes).String(),
"title": book.Title.String,
"matched_media_item_id": bestMatch.BookmannUUID.String(),
"matched_media_item_id": bestMatch.BookhoardUUID.String(),
"confidence": bestMatch.Confidence,
"match_method": bestMatch.MatchMethod,
})