Fixed a bug in RDFCrosswalk (it threw an NPE if an item didn't have any thumbnails).

git-svn-id: http://scm.dspace.org/svn/repo/trunk@2215 9c30dcfa-912a-0410-8fc2-9e0234be79fd
This commit is contained in:
James Rutherford
2007-09-26 09:44:36 +00:00
parent 961d03ea33
commit 9ead74b923

View File

@@ -207,7 +207,13 @@ public class RDFCrosswalk extends Crosswalk
for (int j = 0; j < bitstreams.length; j++)
{
String tName = bitstreams[j].getName() + ".jpg";
Bitstream tb = thumbBundles[0].getBitstreamByName(tName);
Bitstream tb = null;
if (thumbBundles.length > 0)
{
tb = thumbBundles[0].getBitstreamByName(tName);
}
if (tb != null)
{
String thumbUrl = null;