Linca 741e9d70ad
FIX: Don't show move topic for private messages for TL4 (#28871)
In TopicController, in addition to ensure_can_move_posts!, we also
checked if the topic is private message in this line:

```ruby
raise Discourse::InvalidAccess if params[:archetype] == "private_message" && !guardian.is_staff?
```

However, this was not present in `guardian.can_move_posts?`. As a result,
the frontend topic view got an incorrect serialized result, thinking
that TL4 could move the private message post. In fact, once they tried
to move it, they got the `InvalidAccess` error message.

This commit fixes that TL4 will no longer sees the "move to" option in
the "select post" panel for a private message.
2024-09-16 11:30:05 +08:00
..
2022-04-28 11:51:03 +02:00
2024-08-12 10:41:13 +02:00
2024-06-18 10:47:18 +02:00
2023-02-21 10:30:48 +01:00
2024-07-04 10:58:21 +02:00
2024-09-05 09:58:20 +02:00
2020-07-21 15:55:03 +08:00
2024-08-27 10:54:25 -04:00