Tidying up the code a little bit. Added a function that recurs upon exception (NPE's are thrown with update-sentiments occassionally)