aadd first files based on caddy-filemanager

This commit is contained in:
Henrique Dias
2017-06-18 13:57:38 +01:00
parent f185b9893b
commit 20baeeb41a
28 changed files with 10626 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
}