Tentative bugfix
Fix logic error in topic search