Some fixes around environments

This commit is contained in:
Gregory Schier
2024-12-21 11:04:49 -08:00
parent c1d5881167
commit 61d094d9fd
20 changed files with 95 additions and 46 deletions

View File

@@ -40,7 +40,8 @@ export const EnvironmentEditDialog = function ({ initialEnvironment }: Props) {
const selectedEnvironment = allEnvironments.find((e) => e.id === selectedEnvironmentId);
const handleCreateEnvironment = async () => {
const e = await createEnvironment.mutateAsync();
if (baseEnvironment == null) return;
const e = await createEnvironment.mutateAsync(baseEnvironment);
if (e == null) return;
setSelectedEnvironmentId(e.id);
};