mirror of
https://github.com/qdm12/ddns-updater.git
synced 2026-07-31 01:38:17 -04:00
- Return concrete structs - Accept interfaces - Define narrow interfaces locally where needed
16 lines
242 B
Go
16 lines
242 B
Go
package server
|
|
|
|
import (
|
|
"context"
|
|
|
|
"github.com/qdm12/ddns-updater/internal/records"
|
|
)
|
|
|
|
type Database interface {
|
|
SelectAll() (records []records.Record)
|
|
}
|
|
|
|
type UpdateForcer interface {
|
|
ForceUpdate(ctx context.Context) (errors []error)
|
|
}
|