Skip to content

Commit

Permalink
v8 — fix bug field_include depth 2+
Browse files Browse the repository at this point in the history
  • Loading branch information
daohoangson committed Feb 24, 2017
1 parent 65260a5 commit 1989448
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ android {

minSdkVersion 21
targetSdkVersion 25
versionCode 7
versionCode 8
versionName "1.0.0"

// oops, too many dependencies apparently?
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -515,8 +515,13 @@ Params andFieldsInclude(Class<? extends ApiModel> clazz, StringBuilder valueBuil
}

if (ApiModel.class.isAssignableFrom(fieldType)) {
String fieldPrefix = serializedName;
if (!TextUtils.isEmpty(prefix)) {
fieldPrefix = String.format("%s.%s", prefix, fieldPrefix);
}

//noinspection unchecked
andFieldsInclude((Class<? extends ApiModel>) fieldType, valueBuilder, serializedName);
andFieldsInclude((Class<? extends ApiModel>) fieldType, valueBuilder, fieldPrefix);
continue;
}

Expand Down

0 comments on commit 1989448

Please sign in to comment.