Modify ↓

Opened 9 days ago

Closed 8 days ago

#24970 closed task (fixed)

[patch] Fix Sonar issues in ApiUrlTestTask

Reported by: DanProgs <Abenteurer.2901@…> Owned by: DanProgs <Abenteurer.2901@…>
Priority: normal Milestone: 26.09
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 (2)

patch-Fix-Sonar-issues-in-ApiUrlTestTask.patch​ (3.6 KB ) - added by DanProgs <Abenteurer.2901@…> 9 days ago.
patch_24970-Fix-Sonar-issues-in-ApiUrlTestTask.patch​ (3.6 KB ) - added by DanProgs <Abenteurer.2901@…> 8 days ago.

Download all attachments as: .zip

Change History (7)

by DanProgs <Abenteurer.2901@…>, 9 days ago

comment:1 by stoecker, 8 days ago

Owner: changed from team to DanProgs <Abenteurer.2901@…>
Status: new → needinfo

Same issue as in 24950. This breaks I18n.

comment:2 by stoecker, 8 days ago

Milestone: → 26.09

by DanProgs <Abenteurer.2901@…>, 8 days ago

comment:3 by DanProgs <Abenteurer.2901@…>, 8 days ago

Thanks for pointing that out. It should be all set now.

comment:4 by DanProgs <Abenteurer.2901@…>, 8 days ago

Status: needinfo → new

comment:5 by stoecker, 8 days ago

Resolution: → fixed
Status: new → closed

In 19662/josm:

fix #24970 - patch by DanProgs (modified) - fix sonar issues

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain DanProgs <Abenteurer.2901@…>.
as The resolution will be set.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.