If a bank shuts down ,does the customer still have to pay any line of credit, mortgage or credit cards owed to that institution?
It is high unlikely that any of our Big Six Banks (CIBC, TD, BMO, RBC, Scotia, or National) would ever shut down. Those Banks are considered to be "too big to fail."
If one of those Banks were somehow insolvent, it would simply be merged with another Bank.
Lines of Credit, Mortgages and Credit Cards are Assets for the Bank; another Bank would simply take over those Assets and you make your payments to the Bank that took over your accounts.
TD and RBC are significantly larger than the other four; and a failure of either of those Banks would have global consequences.