#235: rename Language column to Type; attachments show file extension #237

Merged
fen merged 1 commits from fix-235 into dev 2026-09-10 22:14:57 +00:00
Collaborator

Fix attempt 1. Ref #235.

  • history/mine table column Language -> Type (sort key type, sortVal handles it)
  • /api/public and /api/mine rows gain type: file extension (lowercase, no dot) for attachment pastes, stored language otherwise, default text
  • paste page stats label Language -> Type; summary line and get-paste JSON gain the same type value
  • store list queries LEFT JOIN attachments for the filename; helpers tested in internal/api/issue235_type_test.go

Verified: go build + go test pass; local server rendered check via CDP shows Type header and badges python/text/pdf for text vs file pastes; mine API returns type correctly.

Fix attempt 1. Ref #235. - history/mine table column Language -> Type (sort key `type`, sortVal handles it) - /api/public and /api/mine rows gain `type`: file extension (lowercase, no dot) for attachment pastes, stored language otherwise, default `text` - paste page stats label Language -> Type; summary line and get-paste JSON gain the same type value - store list queries LEFT JOIN attachments for the filename; helpers tested in internal/api/issue235_type_test.go Verified: go build + go test pass; local server rendered check via CDP shows Type header and badges python/text/pdf for text vs file pastes; mine API returns type correctly.
fen added 1 commit 2026-09-10 22:13:47 +00:00
#235: rename Language column to Type; attachment pastes show file extension
CI / docker (pull_request) Skipped
CI / test (pull_request) Successful in 43s
0008b8ce0c
- history/mine table column 'Language' -> 'Type' (data-sort key 'type')
- /api/public and /api/mine rows gain a 'type' field: file extension for
  attachment pastes, stored language otherwise (default 'text')
- paste page stats label 'Language' -> 'Type'; summary line uses the same
  label; get-paste JSON gains 'type'
- store list queries LEFT JOIN attachments to expose the filename
- table.js sorting accepts the 'type' key
fen merged commit 5075374abe into dev 2026-09-10 22:14:57 +00:00
Sign in to join this conversation.