forked from security/hakurei
internal/app: update doc comments
A lot of these comments are quite old and have not been updated to reflect changes. Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
@@ -3,6 +3,7 @@ package app
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"log"
|
||||
"sync"
|
||||
|
||||
"hakurei.app/hst"
|
||||
@@ -22,6 +23,14 @@ func New(ctx context.Context, os sys.State) (App, error) {
|
||||
return a, err
|
||||
}
|
||||
|
||||
func MustNew(ctx context.Context, os sys.State) App {
|
||||
a, err := New(ctx, os)
|
||||
if err != nil {
|
||||
log.Fatalf("cannot create app: %v", err)
|
||||
}
|
||||
return a
|
||||
}
|
||||
|
||||
type app struct {
|
||||
id *stringPair[state.ID]
|
||||
sys sys.State
|
||||
|
||||
Reference in New Issue
Block a user