Electrochemical degradation of polyaniline