when article have empty tags list, It causes App Crash
365/com.google.developer.udacityalumni E/AndroidRuntime: FATAL EXCEPTION: IntentService[AlumIntentService]
Process: com.google.developer.udacityalumni, PID: 1239
java.lang.IllegalArgumentException: n <= 0: 0
at java.util.Random.nextInt(Random.java:182)
at com.google.developer.udacityalumni.service.AlumIntentService.addArticles(AlumIntentService.java:54)
at com.google.developer.udacityalumni.service.AlumIntentService.onHandleIntent(AlumIntentService.java:108)
at android.app.IntentService$ServiceHandler.handleMessage(IntentService.java:66)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.os.HandlerThread.run(HandlerThread.java:61)
Steps to reproduce
when article have empty tags list, It causes App Crash
check last article item in json response
Expected behavior
AlumIntentService
should check for empty tag list in json response before using it.