Update htmly.php

This commit is contained in:
Dan 2025-07-04 19:19:57 +07:00
commit f5c1a4812a

View file

@ -296,7 +296,7 @@ get('/author/:name', function ($name) {
$author = $author[0]; $author = $author[0];
} else { } else {
$userConfig = 'config/users/' . $name . '.ini'; $userConfig = 'config/users/' . $name . '.ini';
if (file_exists($userConfig)) { if (file_exists($userConfig) || !empty($posts)) {
$author = default_profile(safe_html(strip_tags($name))); $author = default_profile(safe_html(strip_tags($name)));
} else { } else {
not_found(); not_found();
@ -382,7 +382,12 @@ get('/author/:name/feed', function ($name) {
if (isset($author[0])) { if (isset($author[0])) {
$author = $author[0]; $author = $author[0];
} else { } else {
$author = default_profile(safe_html(strip_tags($name))); $userConfig = 'config/users/' . $name . '.ini';
if (file_exists($userConfig) || !empty($posts)) {
$author = default_profile(safe_html(strip_tags($name)));
} else {
not_found();
}
} }
// Show an RSS feed // Show an RSS feed