sandbox: move out of internal
Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
19
sandbox/output.go
Normal file
19
sandbox/output.go
Normal file
@@ -0,0 +1,19 @@
|
||||
package sandbox
|
||||
|
||||
var msg Msg = new(DefaultMsg)
|
||||
|
||||
func GetOutput() Msg { return msg }
|
||||
func SetOutput(v Msg) {
|
||||
if v == nil {
|
||||
msg = new(DefaultMsg)
|
||||
} else {
|
||||
msg = v
|
||||
}
|
||||
}
|
||||
|
||||
func wrapErrSuffix(err error, a ...any) error {
|
||||
if err == nil {
|
||||
return nil
|
||||
}
|
||||
return msg.WrapErr(err, append(a, err)...)
|
||||
}
|
||||
Reference in New Issue
Block a user