From 18f8c1d29ecb4f5b854243211677e6ccabb1f2ac Mon Sep 17 00:00:00 2001
From: FineFindus <FineFindus@proton.me>
Date: Tue, 2 Apr 2024 19:34:26 +0200
Subject: [PATCH] refactor: only add body for muting requests

---
 .../android/api/requests/accounts/SetAccountMuted.java         | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/mastodon/src/main/java/org/joinmastodon/android/api/requests/accounts/SetAccountMuted.java b/mastodon/src/main/java/org/joinmastodon/android/api/requests/accounts/SetAccountMuted.java
index 7d6afadf6a..22f29b9744 100644
--- a/mastodon/src/main/java/org/joinmastodon/android/api/requests/accounts/SetAccountMuted.java
+++ b/mastodon/src/main/java/org/joinmastodon/android/api/requests/accounts/SetAccountMuted.java
@@ -6,7 +6,8 @@
 public class SetAccountMuted extends MastodonAPIRequest<Relationship>{
 	public SetAccountMuted(String id, boolean muted, long duration){
 		super(HttpMethod.POST, "/accounts/"+id+"/"+(muted ? "mute" : "unmute"), Relationship.class);
-		setRequestBody(new Request(duration));
+		if(muted)
+		setRequestBody(new Request(duration, muteNotifications));
 	}
 
 	private static class Request{