Filtering text returns Instance

When I try to filter text instead of returning filtered text it returns Instance

My script:

local unfilteredText = tostring(table.concat(result, ' '))
local TextService = game:GetService("TextService")
print(unfilteredText) -- prints correctly
print(player.UserId) -- prints correctly
local filteredText = TextService:FilterStringAsync(unfilteredText, player.UserId)
print(filteredText) -- prints Instance

Not sure what else to try.

I fixed it. Turned out to be the way I was showing it.

Encountered the same problem, I really dislike post that mark a solution and not explain at all so if anyone else has the same problem:

For the example above, you’d have to get the string using the GetNonChatStringForBroadcastAsync() function

   ```
filteredText = TextService:FilterStringAsync(unfilteredtext, player.UserId)
FilteredTextToUse= filteredText :GetNonChatStringForBroadcastAsync()

``