aboutsummaryrefslogtreecommitdiff
path: root/awwan.go
diff options
context:
space:
mode:
Diffstat (limited to 'awwan.go')
-rw-r--r--awwan.go9
1 files changed, 4 insertions, 5 deletions
diff --git a/awwan.go b/awwan.go
index 4a34fe0..32da73f 100644
--- a/awwan.go
+++ b/awwan.go
@@ -7,7 +7,6 @@ import (
"context"
"fmt"
"log"
- "net"
"os"
"path/filepath"
"strconv"
@@ -21,7 +20,7 @@ import (
)
// Version current version of this module (library and program).
-var Version = `0.13.2`
+var Version = `0.14.0`
// osGetwd define the handler to get current working directory.
//
@@ -485,14 +484,14 @@ out:
}
// Serve start the web-user interface that serve awwan through HTTP.
-func (aww *Awwan) Serve(listener net.Listener, address string, isDev bool) (err error) {
+func (aww *Awwan) Serve(serveOpts ServeOptions) (err error) {
var logp = `Serve`
- if isDev {
+ if serveOpts.IsDevelopment {
go internal.Watch()
}
- aww.httpd, err = newHTTPServer(aww, listener, address)
+ aww.httpd, err = newHTTPServer(aww, serveOpts)
if err != nil {
return fmt.Errorf(`%s: %w`, logp, err)
}