fixed the problem that definitions from external references were not loaded properly

URLs should not be used for validation.  A url can contain valid JSON data without having ".json" in it.  Likewise, a url with '.json' doesn't necessarily contain valid JSON.