!246 feat: add isError and isSuccess method

Merge pull request !246 from runphp/N/A
pull/248/MERGE
若依 2 years ago committed by Gitee
commit 11d8274462
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

@ -102,4 +102,12 @@ public class R<T> implements Serializable
{
this.data = data;
}
public Boolean isError() {
return !isSuccess();
}
public Boolean isSuccess() {
return R.SUCCESS == getCode();
}
}

Loading…
Cancel
Save