Skip to content

Commit 1c9b5c6

Browse files
committed
Better to notify the user
Signed-off-by: Umair Khan <[email protected]>
1 parent 19e1aa5 commit 1c9b5c6

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

App/src/main/java/in/ac/dtu/subtlenews/MainFragment.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,8 @@ protected ArrayList<JSONObject> doInBackground(Void... v) {
120120
e.printStackTrace();
121121
if (Utils.isNetworkConnected(getActivity())) {
122122
new UpdateNews(getActivity()).execute();
123+
} else {
124+
Toast.makeText(getActivity(), "Please turn on your internet connection!", Toast.LENGTH_SHORT).show();
123125
}
124126

125127
}

0 commit comments

Comments
 (0)