Commit 7c1dff4f by Simeon Markind

Final test version

parent 152a9578
......@@ -55,8 +55,10 @@ public class MainActivity extends AppCompatActivity {
public void onClick(View v) {
//Build the URL
Integer wardInt = Integer.parseInt(mWard.getText().toString());
if(wardInt < 0 || wardInt > 50){
Toast.makeText(getApplicationContext(), "Invalid Ward Number", Toast.LENGTH_SHORT);
if(wardInt <= 0 || wardInt > 50){
System.out.println("Invalid Ward Number");
Toast.makeText(getApplicationContext(),
"Invalid Ward Number", Toast.LENGTH_SHORT).show();
} else {
String url = createURL(mWard.getText().toString());
fetchTop3(url);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment