Influence of immobilising anions on the redox switching of polyaniline