Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
2.7
-
None
-
None
-
Patch
Description
On the team list report the "picUrl" property appears in the table, although no other properties are set for that team member.
Given the following team list in the pom.xml:
<developers> <developer> <id>abotos</id> <name>Anghel Botos</name> <email>anghel.botos@someemailprovider.com</email> <properties> <picUrl>images/avatars/abotos.png</picUrl> </properties> </developer> </developers>
Due to the following lines of code in TeamListReport.java:
Properties properties = unit.getProperties(); boolean hasPicUrl = properties.contains( "picUrl" ); if ( hasPicUrl ) { requiredHeaders.put( IMAGE, Boolean.TRUE ); } boolean isJustAnImageProperty = properties.size() == 1 && hasPicUrl; if ( !isJustAnImageProperty && !properties.isEmpty() ) { requiredHeaders.put( PROPERTIES, Boolean.TRUE ); }
hasPicUrl evaluates to false because the check is done using contains not containsKey, and thus isJustAnImageProperty evaluates also to false leading to the Properties column being added to the team members table and the picUrl property being displayed in that column in the table, although the Properties column should not be present for this case.
Attachments
Attachments
Issue Links
- is depended upon by
-
MPIR-277 picUrl displays image but also causes Properties column to appear
- Closed