Opened 50 minutes ago
#24970 new task
[patch] Fix Sonar issues in ApiUrlTestTask
| Reported by: | Owned by: | team | |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | Core | Version: | |
| Keywords: | Cc: |
Description
The deprecated URL constructor in ApiUrlTestTask has been updated, and the exception handling has been adjusted (changing MalformedURLException to IllegalArgumentException | MalformedURLException). The recurring string "Connection to API failed" has been defined as a constant, and the responseCode has been stored in a variable. Furthermore, curly braces have been added to control structures, and fields and variables have been declared as final.
see: https://josm.openstreetmap.de/sonar/project/issues?files=src%2Forg%2Fopenstreetmap%2Fjosm%2Fgui%2Fpreferences%2Fserver%2FApiUrlTestTask.java&issueStatuses=CONFIRMED%2COPEN&open=AYtXfRgJQ0Q6PFw6n23f&id=josm
see: https://josm.openstreetmap.de/sonar/project/issues?files=src%2Forg%2Fopenstreetmap%2Fjosm%2Fgui%2Fpreferences%2Fserver%2FApiUrlTestTask.java&issueStatuses=CONFIRMED%2COPEN&open=3a548e29-540e-47f2-bffe-c156ab7ef302&id=josm
see: https://josm.openstreetmap.de/sonar/project/issues?files=src%2Forg%2Fopenstreetmap%2Fjosm%2Fgui%2Fpreferences%2Fserver%2FApiUrlTestTask.java&issueStatuses=CONFIRMED%2COPEN&open=7142450a-1760-4b2b-89cd-10abce9fdb63&id=josm
Attachments (1)
Change History (1)
by , 50 minutes ago
| Attachment: | patch-Fix-Sonar-issues-in-ApiUrlTestTask.patch added |
|---|


