refactor(server): final writeErr migration + ErrNotFound aliases (T3c)
This commit is contained in:
@@ -1,6 +1,10 @@
|
||||
package lidarr
|
||||
|
||||
import "errors"
|
||||
import (
|
||||
"errors"
|
||||
|
||||
"git.fabledsword.com/bvandeusen/minstrel/internal/apierror"
|
||||
)
|
||||
|
||||
// Sentinel errors. Callers branch on these via errors.Is, not on
|
||||
// HTTP status codes — the client maps codes to errors.
|
||||
@@ -15,5 +19,9 @@ var (
|
||||
// Lidarr's monitored set. Distinguished from network/auth errors so admin
|
||||
// handlers can surface it as `lidarr_album_lookup_failed` (502) instead
|
||||
// of `lidarr_unreachable` (503).
|
||||
ErrNotFound = errors.New("lidarr: not found")
|
||||
//
|
||||
// Aliased to apierror.ErrNotFound so handler error mapping (errors.Is
|
||||
// against the shared sentinel) and existing per-package callsites both
|
||||
// resolve to the same pointer.
|
||||
ErrNotFound = apierror.ErrNotFound
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user