mirror of
https://github.com/Dokploy/dokploy.git
synced 2026-06-16 04:35:24 +02:00
[autofix.ci] apply automated fixes
This commit is contained in:
@@ -62,8 +62,9 @@ export const AdvancedEnvironmentSelector = ({
|
||||
const { data: currentUser } = api.user.get.useQuery();
|
||||
|
||||
// Check if user can delete environments
|
||||
const canDeleteEnvironments = currentUser?.role === "owner" ||
|
||||
currentUser?.role === "admin" ||
|
||||
const canDeleteEnvironments =
|
||||
currentUser?.role === "owner" ||
|
||||
currentUser?.role === "admin" ||
|
||||
currentUser?.canDeleteEnvironments === true;
|
||||
|
||||
// Form states
|
||||
|
||||
@@ -264,7 +264,7 @@ export const checkEnvironmentDeletionPermission = async (
|
||||
organizationId: string,
|
||||
) => {
|
||||
const member = await findMemberById(userId, organizationId);
|
||||
|
||||
|
||||
if (!member) {
|
||||
throw new TRPCError({
|
||||
code: "UNAUTHORIZED",
|
||||
|
||||
Reference in New Issue
Block a user