Environment: Kunena 7.1.1, Joomla 6.2.0, PHP 8.5.13 (Apache mod_php), MariaDB 12.3.4, Debian 12. Site language en-GB.
---
**1. Guests opening a category they can't read get "500 Internal Server Error" instead of 401/403**
Steps: create a category with access level Registered, log out, and open the category URL (e.g. `/forum/members-only`).
Expected: HTTP 401 with Kunena's "no access" message and the login form.
Actual: HTTP 500, with the page heading "500 Internal Server Error :" and an empty message. We saw this on Joomla 5 as well as Joomla 6.
Cause: `libraries/kunena/src/Forum/Category/KunenaCategory.php`, `tryAuthorise()`, line 841:
```php
if ($throw && $exception) {
throw new $exception();
}
```
`authoriseRead()` already returns an exception object, for example `new KunenaExceptionAuthorise(Text::_('COM_KUNENA_NO_ACCESS'), 401)`. `new $exception()` creates a new, empty instance of the same class, with no message and code 0. `KunenaExceptionAuthorise::getResponseCode()` then falls back to 500.
Fix: throw the object that `authoriseRead()` returned, as `KunenaTopic`, `KunenaMessage`, `KunenaUser`, `KunenaAttachment` and `KunenaAnnouncement` already do:
```php
if ($throw && $exception) {
throw $exception;
}
```
With this one-line change, guests get 401 "Unauthorized" plus the login form, and the rest of the forum is unaffected.
---
**2. When RSS is disabled, feed URLs return HTTP 500**
With "Enable RSS Feeds" set to No, any feed URL (e.g. `/forum/recent/feed?format=feed&type=rss` or `/forum/<category>/feed?format=feed&type=rss`) returns:
```xml
<error>
<code>500</code>
<message>COM_KUNENA_RSS_DISABLED</message>
</error>
```
The error is thrown with code 500 in:
- `components/com_kunena/src/Controller/Application/Category/Feed/CategoryDisplay.php` (line 68)
- `components/com_kunena/src/Controller/Application/Topics/Feed/TopicsDisplay.php` (line 75)
- `components/com_kunena/src/View/Category/HtmlViewFeed.php` (line 46)
A feed that the administrator has switched off isn't a server error. Search engines and feed readers keep requesting old feed links, so these 500s fill the server error statistics. A 404 (or 403) would be more appropriate. On our site, under Joomla 5, the same URLs were logged as 404s; after the upgrade to Joomla 6 they became 500s.
---
**3. Language strings are not translated in feed output**
In `format=feed` requests, strings from `components/com_kunena/language/en-GB/com_kunena.views.ini` are shown as raw keys:
- The disabled-feed error above shows `COM_KUNENA_RSS_DISABLED` rather than "Sorry, RSS feeds have been disabled by administrator."
- With RSS enabled, the topics feed title is `COM_KUNENA_VIEW_TOPICS_DEFAULT_MODE_DEFAULT - <site name> Forum` rather than "Recent Discussions - ...".
Both keys exist in `com_kunena.views.ini`, so it looks as if that language file is not loaded for the feed format.
---
Thanks for Kunena. Happy to test a fix or give more detail.