Added some comments for clarity. Matches file types now.