Skip to content

Commit 9140776

Browse files
committed
feat: provide instance name through dandischema instance config
instead of a hardcoded value
1 parent 20eaa9f commit 9140776

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

dandiapi/api/models/version.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -217,9 +217,11 @@ def _populate_metadata(self):
217217
),
218218
'manifestLocation': manifest_location(self),
219219
'name': self.name,
220-
'identifier': f'DANDI:{self.dandiset.identifier}',
220+
'identifier': f'{settings.DANDI_SCHEMA_INSTANCE_CONFIG.instance_name}:'
221+
f'{self.dandiset.identifier}',
221222
'version': self.version,
222-
'id': f'DANDI:{self.dandiset.identifier}/{self.version}',
223+
'id': f'{settings.DANDI_SCHEMA_INSTANCE_CONFIG.instance_name}:'
224+
f'{self.dandiset.identifier}/{self.version}',
223225
'repository': settings.DANDI_WEB_APP_URL,
224226
'url': (
225227
f'{settings.DANDI_WEB_APP_URL}/dandiset/{self.dandiset.identifier}/{self.version}'

0 commit comments

Comments
 (0)