From 3fb0d1c15df6fb8c8d05e22fc96b7d187d09a2d1 Mon Sep 17 00:00:00 2001 From: Joakim Roubert Date: Wed, 13 May 2020 22:29:52 +0200 Subject: [PATCH] Update after code review Simplified local variable declaration as suggested by phenixblue. Signed-off-by: Joakim Roubert --- cluster/gce/gci/configure-helper.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/cluster/gce/gci/configure-helper.sh b/cluster/gce/gci/configure-helper.sh index 590b5f11bbc..7992c6985c6 100644 --- a/cluster/gce/gci/configure-helper.sh +++ b/cluster/gce/gci/configure-helper.sh @@ -246,13 +246,12 @@ function get-or-generate-uuid(){ fi # each line of the ssdmap looks like "${device} persistent-uuid" + local myuuid if grep -q "${device}" "${ssdmap}"; then #create symlink based on saved uuid - local myuuid myuuid=$(grep "${device}" "${ssdmap}" | cut -d ' ' -f 2) else # generate new uuid and add it to the map - local myuuid if ! myuuid=$(uuidgen); then echo "Failed to generate valid UUID with uuidgen" >&2 exit 2