diff --git a/etc/cgroup.release_common.example.in b/etc/cgroup.release_common.example.in
index 8c1bfdd0f330d59e16fafc2bf16c4266c7392d2c..8d12f45c21c354e05eaea64c3dad89d1d0187b93 100644
--- a/etc/cgroup.release_common.example.in
+++ b/etc/cgroup.release_common.example.in
@@ -69,15 +69,14 @@ then
     esac
 fi
 
+# try to extract the uid cgroup from the input one
+# ( extract /uid_% from /uid%/job_*...)
+uidcg=${rmcg%/job_*}
+
 # kernel call
 if [[ $# -eq 1 ]]
 then
 
-    rmcg=${mountdir}$@
-
-    # try to extract the uid cgroup from the input one
-    # ( extract /uid_% from /uid%/job_*...)
-    uidcg=${rmcg%/job_*}
     if [[ ${uidcg} == ${rmcg} ]]
     then
 	# not a slurm job pattern, perhaps the uidcg, just remove
@@ -98,10 +97,6 @@ then
 elif [[ $# -eq 2 ]] && [[ $1 == "sync" ]]
 then
 
-    shift
-    rmcg=${mountdir}$@
-    uidcg=${rmcg%/job_*}
-
     # remove this cgroup
     if [[ -d ${rmcg} ]]
     then