[MGNLEE-766] ContentMap#get method doesn't consider the PropertyType.REFERENCE type as array Created: 17/Mar/23 Updated: 17/Mar/23 Resolved: 17/Mar/23 |
|
| Status: | Closed |
| Project: | Magnolia DX Core |
| Component/s: | None |
| Affects Version/s: | 6.2.29 |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Neutral |
| Reporter: | Carlos Cantalapiedra | Assignee: | Unassigned |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Σ Remaining Estimate: | Not Specified | Remaining Estimate: | Not Specified |
| Σ Time Spent: | Not Specified | Time Spent: | Not Specified |
| Σ Original Estimate: | Not Specified | Original Estimate: | Not Specified |
| Issue Links: |
|
|||||||||||||||||||||||||
| Sub-Tasks: |
|
|||||||||||||||||||||||||
| Template: | ||||||||||||||||||||||||||
| Acceptance criteria: |
Empty
|
|||||||||||||||||||||||||
| Task DoD: |
[ ]*
Doc/release notes changes? Comment present?
[ ]*
Downstream builds green?
[ ]*
Solution information and context easily available?
[ ]*
Tests
[ ]*
FixVersion filled and not yet released
[ ] 
Architecture Decision Record (ADR)
|
|||||||||||||||||||||||||
| Team: | ||||||||||||||||||||||||||
| Description |
|
When the ContentMap class is used for retrieve a REFERENCE property as jcr:predecessor it will fail because the get method won't consider it as multivalue. It would be better to include at the else if (type == PropertyType.REFERENCE) statement another check like "if (prop.isMultiple())" so for those cases like jcr:predecessors, it won't thrown error as:
|