diff --git a/build.gradle b/build.gradle index b931845..3d65f21 100644 --- a/build.gradle +++ b/build.gradle @@ -3,7 +3,7 @@ apply plugin: 'me.tatarka.retrolambda' android { compileSdkVersion 25 - buildToolsVersion "25.0.2" + buildToolsVersion "25.0.3" compileOptions { sourceCompatibility JavaVersion.VERSION_1_8 diff --git a/src/main/java/ru/touchin/templates/googlejson/GoogleJsonModel.java b/src/main/java/ru/touchin/templates/googlejson/GoogleJsonModel.java index f150dbc..a695e95 100644 --- a/src/main/java/ru/touchin/templates/googlejson/GoogleJsonModel.java +++ b/src/main/java/ru/touchin/templates/googlejson/GoogleJsonModel.java @@ -78,8 +78,11 @@ public abstract class GoogleJsonModel extends ApiModel { * @throws ValidationException Exception of validation. */ protected static void validateNotNull(@Nullable final Object object) throws ValidationException { - if (isNullOrMissed(object)) { - throw new ValidationException("Not nullable object is null or missed at " + Lc.getCodePoint(null, 1)); + if (isNull(object)) { + throw new ValidationException("Not nullable object is null at " + Lc.getCodePoint(null, 1)); + } + if (isMissed(object)) { + throw new ValidationException("Not nullable object is missed at " + Lc.getCodePoint(null, 1)); } }