diff --git a/webapp/src/edu/cornell/mannlib/vitro/webapp/search/solr/documentBuilding/ExcludeBasedOnType.java b/webapp/src/edu/cornell/mannlib/vitro/webapp/search/solr/documentBuilding/ExcludeBasedOnType.java index b2b6094bb..97c9c5aa6 100644 --- a/webapp/src/edu/cornell/mannlib/vitro/webapp/search/solr/documentBuilding/ExcludeBasedOnType.java +++ b/webapp/src/edu/cornell/mannlib/vitro/webapp/search/solr/documentBuilding/ExcludeBasedOnType.java @@ -34,9 +34,9 @@ public class ExcludeBasedOnType implements SearchIndexExcluder { if( typeURIinExcludeList( ind.getVClass() )) return SKIP_MSG; - List vclasses = ind.getVClasses(); - if( vclasses == null) - return null; + List vclasses = new ArrayList(); + vclasses.addAll( ind.getVClasses()!=null?ind.getVClasses():Collections.EMPTY_LIST ); + vclasses.addAll( ind.getVClasses(true)!=null?ind.getVClasses(true):Collections.EMPTY_LIST ); for( VClass vclz : vclasses){ if( typeURIinExcludeList( vclz )) diff --git a/webapp/test/edu/cornell/mannlib/vitro/webapp/search/solr/documentBuilding/ExcludeBasedOnTypeTest.java b/webapp/test/edu/cornell/mannlib/vitro/webapp/search/solr/documentBuilding/ExcludeBasedOnTypeTest.java index 710cc01b7..908b62354 100644 --- a/webapp/test/edu/cornell/mannlib/vitro/webapp/search/solr/documentBuilding/ExcludeBasedOnTypeTest.java +++ b/webapp/test/edu/cornell/mannlib/vitro/webapp/search/solr/documentBuilding/ExcludeBasedOnTypeTest.java @@ -33,7 +33,7 @@ public class ExcludeBasedOnTypeTest { public void testCheckForExclusion2() { ExcludeBasedOnType ebot = new ExcludeBasedOnType(); - ebot.addTypeToExclude("http://xmlns.com/foaf/0.1/KillerRobot"); + ebot.addTypeToExclude("http://example.com/KillerRobot"); IndividualImpl ind = new IndividualImpl(); ind.setURI("http://example.com/n2343");