Cleaned up, uses System::mkdir instead of mkdir