Solution found:
"It seems that After Effects (and all other CC applications that use audio) generates some settings in the Audio and MIDI device setup found under Applications>Utilities.
I think they are ways to make specific audio setups for these applications. You can probably edit these settings to match the system setup, but I just deleted them and now everything works fine."