1
0
mirror of https://github.com/astaxie/beego.git synced 2025-07-07 02:30:18 +00:00
This commit is contained in:
astaxie
2016-01-17 23:48:17 +08:00
parent 9b2597be68
commit 90d1349665
9 changed files with 11 additions and 11 deletions

View File

@ -670,7 +670,7 @@ func MapGet(arg1 interface{}, arg2 ...interface{}) (interface{}, error) {
if arg1Type.Kind() == reflect.Map && len(arg2) > 0 {
// check whether arg2[0] type equals to arg1 key type
// if they are different, make convertion
// if they are different, make conversion
arg2Val := reflect.ValueOf(arg2[0])
arg2Type := reflect.TypeOf(arg2[0])
if arg2Type.Kind() != arg1Type.Key().Kind() {