Moved refreshing call from onRefresh() (MainActivity) to MainPresenter (getFirstLevel())

This commit is contained in:
ChronosX88 2019-01-05 15:34:02 +04:00
parent 9fc86b219b
commit d53165fe48
No known key found for this signature in database
GPG Key ID: 8F92E090A87804AA
2 changed files with 1 additions and 1 deletions

View File

@ -21,6 +21,7 @@ public class MainPresenter implements MainContract.Presenter {
@Override
public void getFirstLevel() {
mView.swipeLayoutSetRefreshing(true);
try {
coreModel.reinitializeApi();
} catch (IllegalStateException e) {

View File

@ -104,7 +104,6 @@ public class MainActivity extends AppCompatActivity
@Override
public void onRefresh() {
mSwipeRefreshLayout.setRefreshing(true);
mPresenter.getFirstLevel();
}