if ((proto == null) && isValidTypeName(name)) {  createPrototype(name, (Repository) list[i]);
if (proto == null) {  if (isValidTypeName(name)) createPrototype(name, (Repository) list[i]);
    private void checkRepository(Repository repository) throws IOException {        Repository[] list = repository.getRepositories();        for (int i = 0; i < list.length; i++) {            if (list[i].isScriptRoot()) {                // this is an embedded top-level script repository                 checkRepository(list[i]);            } else {                // its an prototype                String name = null;                name = ((Repository) list[i]).getShortName();                Prototype proto = getPrototype(name);                // if prototype doesn't exist, create it                if ((proto == null) && isValidTypeName(name)) {                    // create new prototype                    createPrototype(name, (Repository) list[i]);                } else {                    proto.addRepository((Repository) list[i]);                }            }        }        Iterator resources = repository.getResources();        while (resources.hasNext()) {            // check for jar files to add to class loader            Resource resource = (Resource) resources.next();            String name = resource.getName();            if (name.endsWith(".jar")) {                if (!jarfiles.contains(name)) {                    jarfiles.add(name);                    loader.addURL(resource.getUrl());                }            }        }    }