Skip to content

Commit 019d703

Browse files
joshuacordsbrianchandotcom
authored andcommitted
LPD-61237 search-experiences-service: Collection Providers are only available in their instances
https://liferay.atlassian.net/browse/LPD-61237
1 parent 85e8fe4 commit 019d703

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

modules/dxp/apps/search-experiences/search-experiences-service/src/main/java/com/liferay/search/experiences/internal/info/collection/provider/SXPBlueprintInfoCollectionProvider.java

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
import com.liferay.petra.string.StringBundler;
1818
import com.liferay.petra.string.StringPool;
1919
import com.liferay.portal.kernel.feature.flag.FeatureFlagManagerUtil;
20+
import com.liferay.portal.kernel.security.auth.CompanyThreadLocal;
2021
import com.liferay.portal.kernel.service.ServiceContext;
2122
import com.liferay.portal.kernel.service.ServiceContextThreadLocal;
2223
import com.liferay.portal.kernel.theme.ThemeDisplay;
@@ -89,7 +90,14 @@ public List<InfoFilter> getSupportedInfoFilters() {
8990

9091
@Override
9192
public boolean isAvailable() {
92-
return FeatureFlagManagerUtil.isEnabled("LPS-129412");
93+
if (FeatureFlagManagerUtil.isEnabled("LPS-129412") &&
94+
(sxpBlueprint.getCompanyId() ==
95+
CompanyThreadLocal.getCompanyId())) {
96+
97+
return true;
98+
}
99+
100+
return false;
93101
}
94102

95103
protected SearchRequestBuilder getSearchRequestBuilder(

0 commit comments

Comments
 (0)