Disable follow request buttons once has relationship

This commit is contained in:
Lim Chee Aun 2023-10-09 19:44:54 +08:00
parent 39f7d4e00d
commit a697fb04df

View file

@ -17,7 +17,7 @@ function FollowRequestButtons({ accountID, onChange }) {
<p class="follow-request-buttons"> <p class="follow-request-buttons">
<button <button
type="button" type="button"
disabled={uiState === 'loading'} disabled={uiState === 'loading' || hasRelationship}
onClick={() => { onClick={() => {
setUIState('loading'); setUIState('loading');
setRequestState('accept'); setRequestState('accept');
@ -40,7 +40,7 @@ function FollowRequestButtons({ accountID, onChange }) {
</button>{' '} </button>{' '}
<button <button
type="button" type="button"
disabled={uiState === 'loading'} disabled={uiState === 'loading' || hasRelationship}
class="light danger" class="light danger"
onClick={() => { onClick={() => {
setUIState('loading'); setUIState('loading');