Replace tabs with spaces
Change $output only if subotage is successfull