visibleThread method
The thread threadId when principalId sees it; else 404 not_found.
Implementation
JsonMap visibleThread(String principalId, String threadId) {
if (!seesThread(principalId, threadId)) {
throw const FakeProblem(404, 'not_found');
}
return threads[threadId]!;
}