Fix tab vs space issues in code

Changed all tabs to be spaces to avoid problems between editors.