Fix file and jar handling while scanning for classes and properties files