mirror of
https://github.com/kataras/iris.git
synced 2025-12-27 14:57:05 +00:00
minor changes to MVC, see HISTORY.md#Next for more
This commit is contained in:
@@ -201,6 +201,9 @@ func lookupFields(elem reflect.Value, skipUnexported bool, onlyZeros bool, paren
|
||||
func lookupNonZeroFieldValues(elem reflect.Value) (nonZeroFields []reflect.StructField) {
|
||||
fields, _ := lookupFields(elem, true, false, nil)
|
||||
for _, f := range fields {
|
||||
if structFieldIgnored(f) {
|
||||
continue // re-check here for ignored struct fields so we don't include them on dependencies. Non-zeroes fields can be static, even if they are functions.
|
||||
}
|
||||
if fieldVal := elem.FieldByIndex(f.Index); goodVal(fieldVal) && !isZero(fieldVal) {
|
||||
/* && f.Type.Kind() == reflect.Ptr &&*/
|
||||
nonZeroFields = append(nonZeroFields, f)
|
||||
|
||||
Reference in New Issue
Block a user