Skip to content

Fix disable account to use savings account id #2013

@IITI-tushar

Description

@IITI-tushar

The current account disabling flow uses state.client.id while calling repository.blockAccount(state.client.id). However, blocking an account should require the actual account ID instead of the client ID.
Current Code:

    private fun handleDisableAccount() {
        mutableStateFlow.update {
            it.copy(dialogState = DialogState.Loading)
        }

        // TODO:: this shouldn't work, we need account id to block account
        viewModelScope.launch {
            val result = repository.blockAccount(state.client.id)
            sendAction(DisableAccountResult(result))
        }
    }

Suggested Fix

Update the disable account implementation to use the appropriate account identifier instead of the client ID. Also verify related API/request models if needed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions