+ switch ($url) {
+ case 'https://w3id.org/security/v1':
+ $url = DI::basePath() . '/static/security-v1.jsonld';
+ break;
+ case 'https://w3id.org/identity/v1':
+ $url = DI::basePath() . '/static/identity-v1.jsonld';
+ break;
+ case 'https://www.w3.org/ns/activitystreams':
+ $url = DI::basePath() . '/static/activitystreams.jsonld';
+ break;
+ case 'https://funkwhale.audio/ns':
+ $url = DI::basePath() . '/static/funkwhale.audio.jsonld';
+ break;
+ default:
+ switch (parse_url($url, PHP_URL_PATH)) {
+ case '/schemas/litepub-0.1.jsonld';
+ $url = DI::basePath() . '/static/litepub-0.1.jsonld';
+ break;
+ case '/apschema/v1.2':
+ case '/apschema/v1.9':
+ case '/apschema/v1.10':
+ $url = DI::basePath() . '/static/apschema.jsonld';
+ break;
+ default:
+ Logger::info('Got url', ['url' =>$url]);
+ break;
+ }
+ }
+