merge the 2 _createmd functions

This commit is contained in:
Tobias Powalowski 2023-01-14 14:35:24 +01:00
parent cb0f376254
commit 75ee36409b

View file

@ -549,11 +549,6 @@ _createmd()
_dialog --yesno "Would you like to create ${_RAIDDEV} like this?\n\nLEVEL:\n${_LEVEL}\n\nDEVICES:\n$(while read -r i;do echo "${i}\n"; done < /tmp/.raid)\nSPARES:\n$(while read -r i;do echo "${i}\n"; done < tmp/.raid-spare)" 0 0 && _MDFINISH="DONE"
done
_umountall
_createmd
}
_createmd()
{
_DEVS="$(echo -n "$(cat /tmp/.raid)")"
_SPARES="$(echo -n "$(cat /tmp/.raid-spare)")"
# combine both if spares are available, spares at the end!