Nominee or heir: Who is entitled to receive the money of the deceased?

If the account holder nominates someone to any bank account, after the demise of such a person the duty of a bank is to hand over the deceased's money to the nominee, whose responsibility is...