Closed
Description
The validation that marks unnecessary name attributes in certain web annotations (like @RequestParam
or @PathVariable
) underlines the whole annotation section of the code at the moment, creating the impression that the full annotation statement is not necessary, whereas the attribute about the name is the only piece of the annotation that could be removed.
Instead of marking the complete annotation statement, the validation should only mark the name attribute definition.
Example
public Owner findOwner(@PathVariable(name = "ownerId", required = false) Integer ownerId) {
|-----------------------------------------------|
whereas the marker should only be positioned below the name = "ownerId"
:
public Owner findOwner(@PathVariable(name = "ownerId", required = false) Integer ownerId) {
|--------------|