Closed n-peugnet closed 1 year ago
But as @rob006 pointed out, this behaviour is mostly useful for
DiscussionReferencedPost
:
To be clear, I think that it would be much better to completely hide info about references in DiscussionReferencedPost
, if they're not accessible. So if DiscussionReferencedPost
has info about 2 discussions, but one of them is unavailable, then display info only about one available discussion. If all discussions in DiscussionReferencedPost
are unavailable, then I would hide this event post completely. In this way we can avoid unnecessary noise and unintentional revealing of some information (currently you don't know title of discussion, but you still can see that specific person mentioned this discussion).
So if you decide to not have a setting to enable replacing unavailable discussion with placeholder, there will be no scenario with placeholder at all.
But as @rob006 pointed out, this behaviour is mostly useful for
DiscussionReferencedPost
:To be clear, I think that it would be much better to completely hide info about references in
DiscussionReferencedPost
, if they're not accessible. So ifDiscussionReferencedPost
has info about 2 discussions, but one of them is unavailable, then display info only about one available discussion. If all discussions inDiscussionReferencedPost
are unavailable, then I would hide this event post completely. In this way we can avoid unnecessary noise and unintentional revealing of some information (currently you don't know title of discussion, but you still can see that specific person mentioned this discussion).So if you decide to not have a setting to enable replacing unavailable discussion with placeholder, there will be no scenario with placeholder at all.
After thinking a little bit about it, I think I like this approach. But to implement it properly kind of requires #13 if we filter them in the frontend.
Another problem is that I don't know how to completely invalidate an EventPost
in the frontend. Maybe I could override the view()
method, but it would probably not look good. Maybe the best way would be to filter them from the backend, but not sure how feasible it would be.
This invalidation causes problems for multiple reasons, as @rob006 explained in https://github.com/club-1/flarum-ext-cross-references/pull/31#issuecomment-1435655730:
To summarize:
$request
is null or invalid, thus removing a link that should be present.[unknown discussion]
makes it not only unfollow-able, it removes the information it contains: its text and destination (which are the same in this case).Questions
Should invalidating the link still be an option? And if yes, should it be disabled by default?
@rob006 thought no, or if yes, disabled by default.
What should be the displayed text of the link?
Simply the original content of the message. So this means using the
@url
parameter.What about unknown Short tags?
I think it should not produce a link, as it was not present in the original source.
Should it have
Discussion*
classes?Not sure.
What about the problem of revealing the title of the discussions?
The
[unknown discussion]
placeholder was first added to prevent users from discovering information about hidden discussions (#10). For instance by posting a link to all the discussion ids incrementally, to get access to te title of all the discussions. The link invalidation came later (#15).But as @rob006 pointed out, this behaviour is mostly useful for
DiscussionReferencedPost
:By displaying the original link content instead of
[unknown discussion]
we do not reveal more information that what the message originally contained.