add: ability to edit community title through ui

add: finish README
This commit is contained in:
trisua 2025-04-02 18:44:31 -04:00
parent 7c9d5de535
commit 53cf75b53c
11 changed files with 203 additions and 55 deletions

View file

@ -121,17 +121,14 @@ pub async fn posts_request(
// check for private profile
if other_user.settings.private_profile {
if let Some(ref ua) = user {
if (ua.id != other_user.id) && !ua.permissions.check(FinePermission::MANAGE_USERS) {
if data
if (ua.id != other_user.id) && !ua.permissions.check(FinePermission::MANAGE_USERS) && data
.0
.get_userfollow_by_initiator_receiver(other_user.id, ua.id)
.await
.is_err()
{
return Err(Html(
render_error(Error::NotAllowed, &jar, &data, &user).await,
));
}
.is_err() {
return Err(Html(
render_error(Error::NotAllowed, &jar, &data, &user).await,
));
}
} else {
return Err(Html(
@ -246,17 +243,14 @@ pub async fn following_request(
// check for private profile
if other_user.settings.private_profile {
if let Some(ref ua) = user {
if ua.id != other_user.id {
if data
if ua.id != other_user.id && data
.0
.get_userfollow_by_initiator_receiver(other_user.id, ua.id)
.await
.is_err()
{
return Err(Html(
render_error(Error::NotAllowed, &jar, &data, &user).await,
));
}
.is_err() {
return Err(Html(
render_error(Error::NotAllowed, &jar, &data, &user).await,
));
}
} else {
return Err(Html(
@ -373,17 +367,14 @@ pub async fn followers_request(
// check for private profile
if other_user.settings.private_profile {
if let Some(ref ua) = user {
if ua.id != other_user.id {
if data
if ua.id != other_user.id && data
.0
.get_userfollow_by_initiator_receiver(other_user.id, ua.id)
.await
.is_err()
{
return Err(Html(
render_error(Error::NotAllowed, &jar, &data, &user).await,
));
}
.is_err() {
return Err(Html(
render_error(Error::NotAllowed, &jar, &data, &user).await,
));
}
} else {
return Err(Html(