aadd first files based on caddy-filemanager

Former-commit-id: 20baeeb41a9555cefc3b31b495e24e907736c443
This commit is contained in:
Henrique Dias
2017-06-18 13:57:38 +01:00
parent f185b9893b
commit 1cea7a383d
28 changed files with 2483 additions and 1 deletions

13
utils/types.go Normal file
View File

@@ -0,0 +1,13 @@
package utils
import "reflect"
// IsMap checks if some variable is a map
func IsMap(sth interface{}) bool {
return reflect.ValueOf(sth).Kind() == reflect.Map
}
// IsSlice checks if some variable is a slice
func IsSlice(sth interface{}) bool {
return reflect.ValueOf(sth).Kind() == reflect.Slice
}