REPORT-848: added try catch statements to catch NullPointerException #170
REPORT-848: added try catch statements to catch NullPointerException #170mozzy11 wants to merge 1 commit intoopenmrs:masterfrom
Conversation
…n different forms
| } | ||
| design = rs.saveReportDesign(design); | ||
| return "redirect:" + successUrl; | ||
| }catch(PropertyValueException e) { |
There was a problem hiding this comment.
@mozzy11 , what happens when a NullPointerException is thrown instead?
| } | ||
| design = rs.saveReportDesign(design); | ||
| return "redirect:" + successUrl; | ||
| }catch(PropertyValueException e) { |
There was a problem hiding this comment.
Same applies here and anywhere else in this PR
There was a problem hiding this comment.
I did several testing of that , and instead of a Null Pointer Exception being throen when an empty parameter is passed to the controller, its a PropertyValueEception that is thrown . i think the NPE is already manged by the util methods used there in that specific controller where i was catching the propertValueException
| url.append("&returnUrl=" + returnUrl); | ||
| } | ||
| return "redirect:"+url.toString(); | ||
| }catch(NullPointerException e){ |
There was a problem hiding this comment.
it was only here , where an empty parameter passed to the controller throws a NPE
|
@dkayiwa can this be merged? Screenshot provided in comments here: https://issues.openmrs.org/browse/REPORT-848 |
|
@gracepotma cannot be merged with merge conflicts. 😊 |
|
@mozzy11 can you address the merge conflicts? |
Ticket: https://issues.openmrs.org/browse/REPORT-848