fix: change accept to reject
This commit is contained in:
parent
d03346c0de
commit
193b69b6b1
|
@ -100,7 +100,7 @@ extension NotificationSection {
|
||||||
cell.rejectButton.publisher(for: .touchUpInside)
|
cell.rejectButton.publisher(for: .touchUpInside)
|
||||||
.sink { [weak cell] _ in
|
.sink { [weak cell] _ in
|
||||||
guard let cell = cell else { return }
|
guard let cell = cell else { return }
|
||||||
cell.delegate?.notificationTableViewCell(cell, notification: notification, rejectButtonDidPressed: cell.acceptButton)
|
cell.delegate?.notificationTableViewCell(cell, notification: notification, rejectButtonDidPressed: cell.rejectButton)
|
||||||
}
|
}
|
||||||
.store(in: &cell.disposeBag)
|
.store(in: &cell.disposeBag)
|
||||||
cell.actionImageBackground.backgroundColor = color
|
cell.actionImageBackground.backgroundColor = color
|
||||||
|
|
|
@ -140,7 +140,7 @@ final class NotificationViewModel: NSObject {
|
||||||
|
|
||||||
func rejectFollowRequest(notification: MastodonNotification) {
|
func rejectFollowRequest(notification: MastodonNotification) {
|
||||||
guard let activeMastodonAuthenticationBox = self.activeMastodonAuthenticationBox.value else { return }
|
guard let activeMastodonAuthenticationBox = self.activeMastodonAuthenticationBox.value else { return }
|
||||||
context.apiService.acceptFollowRequest(mastodonUserID: notification.account.id, mastodonAuthenticationBox: activeMastodonAuthenticationBox)
|
context.apiService.rejectFollowRequest(mastodonUserID: notification.account.id, mastodonAuthenticationBox: activeMastodonAuthenticationBox)
|
||||||
.sink { [weak self] completion in
|
.sink { [weak self] completion in
|
||||||
switch completion {
|
switch completion {
|
||||||
case .failure(let error):
|
case .failure(let error):
|
||||||
|
|
Loading…
Reference in New Issue