aboutsummaryrefslogtreecommitdiff
path: root/util/util.go
diff options
context:
space:
mode:
authorFChannel <>2022-05-02 12:07:00 -0700
committerFChannel <>2022-06-19 12:53:29 -0700
commit733f911fadc872933481bcbe087d519ce00372df (patch)
tree54788da4f730bd11934401c1eca48a3c87f08027 /util/util.go
parente80fe14f7985f9e85bfb9582926acd7891455786 (diff)
cleaned up main
Diffstat (limited to 'util/util.go')
-rw-r--r--util/util.go10
1 files changed, 10 insertions, 0 deletions
diff --git a/util/util.go b/util/util.go
index ade5eae..0ffbf01 100644
--- a/util/util.go
+++ b/util/util.go
@@ -251,3 +251,13 @@ func GetContentType(location string) string {
return location
}
}
+
+func CreatedNeededDirectories() {
+ if _, err := os.Stat("./public"); os.IsNotExist(err) {
+ os.Mkdir("./public", 0755)
+ }
+
+ if _, err := os.Stat("./pem/board"); os.IsNotExist(err) {
+ os.MkdirAll("./pem/board", 0700)
+ }
+}