mirror of
https://github.com/DSpace/DSpace.git
synced 2025-10-17 23:13:10 +00:00
getValues should not return null values
This commit is contained in:
@@ -137,7 +137,7 @@ public class Related implements VirtualBean {
|
|||||||
* @param item The item that will be used to find the related item through its relationships
|
* @param item The item that will be used to find the related item through its relationships
|
||||||
* @return The String value of the metadata fields concatened with a seperator as defined
|
* @return The String value of the metadata fields concatened with a seperator as defined
|
||||||
* in the deepest Concatened bean in the chain
|
* in the deepest Concatened bean in the chain
|
||||||
* Will return null if no relationships are found
|
* Will return an empty list if no relationships are found
|
||||||
* @throws SQLException If something goes wrong
|
* @throws SQLException If something goes wrong
|
||||||
*/
|
*/
|
||||||
public List<String> getValues(Context context, Item item) throws SQLException {
|
public List<String> getValues(Context context, Item item) throws SQLException {
|
||||||
@@ -172,7 +172,8 @@ public class Related implements VirtualBean {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return null;
|
//Return an empty list if no relationships were found
|
||||||
|
return new LinkedList<>();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user