Electron localization effects on the conducting state in polyaniline