organize better in sub packages
This commit is contained in:
1 parent
06c1a412a6
commit
f2fbe92591
10 files changed
+47
-35
No files matched your search
@@ -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
|
||||
}
|
||||
Reference in new issue
Block a user