@Override public void onError(SyncServiceException e) { if (e.isNetworkError()) { Crouton.makeText(this, e.getRessourceString(), Style.ALERT).show(); return; } FragmentManager fm = getSupportFragmentManager(); ErrorDialogFragment errorDialog = ErrorDialogFragment.newInstance(e, Extra.UNKNOWN); if (errorDialog == null) return; errorDialog.show(fm, ErrorDialogFragment.TAG); }