fix args not parsed

This commit is contained in:
Aurélie Delhaie
2023-05-07 23:10:29 +02:00
parent 784679592d
commit 6d2fdb0e6b

View File

@@ -10,6 +10,8 @@ func main() {
contentPath := flag.String("content", "content.json", "Set the content configuration path, this file is encoded in JSON")
serverPort := flag.Int("port", 8080, "Set the HTTP Server port")
flag.Parse()
if contentPath == nil {
contentPath = new(string)
*contentPath = "content.json"