fix bug with custom mode and bad source folder