mirror of
https://github.com/SyncrowIOT/backend.git
synced 2025-11-26 13:14:55 +00:00
remove deleted spaces from search results
This commit is contained in:
@ -193,7 +193,15 @@ export class CommunityService {
|
|||||||
})
|
})
|
||||||
.distinct(true);
|
.distinct(true);
|
||||||
if (includeSpaces) {
|
if (includeSpaces) {
|
||||||
matchingCommunityIdsQb.leftJoin('c.spaces', 'space');
|
matchingCommunityIdsQb.leftJoin(
|
||||||
|
'c.spaces',
|
||||||
|
'space',
|
||||||
|
'space.disabled = :disabled AND space.spaceName != :orphanSpaceName',
|
||||||
|
{
|
||||||
|
disabled: false,
|
||||||
|
orphanSpaceName: ORPHAN_SPACE_NAME,
|
||||||
|
},
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (search) {
|
if (search) {
|
||||||
|
|||||||
Reference in New Issue
Block a user