Skip to content
This repository was archived by the owner on Jun 13, 2025. It is now read-only.

Commit 4eb5539

Browse files
committed
review
1 parent 96ddf41 commit 4eb5539

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

core/commands/repository/interactors/activate_measurements.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,14 @@ class ActivateMeasurementsInteractor(BaseInteractor):
1111
@sync_to_async
1212
def execute(
1313
self, repo_name: str, owner_name: str, measurement_type: MeasurementName
14-
):
14+
) -> Dataset:
15+
if not settings.TIMESERIES_ENABLED:
16+
raise ValidationError("Timeseries storage not enabled")
17+
1518
_owner, repo = self.resolve_owner_and_repo(
1619
owner_name, repo_name, only_viewable=True, only_active=True
1720
)
1821

19-
if not settings.TIMESERIES_ENABLED:
20-
raise ValidationError("Timeseries storage not enabled")
21-
2222
dataset, created = Dataset.objects.get_or_create(
2323
name=measurement_type.value,
2424
repository_id=repo.pk,

0 commit comments

Comments
 (0)