Only remove motd instructions once

This commit is contained in:
Bob Mottram 2017-08-05 22:15:32 +01:00
parent c713c613c9
commit bd86c4b19a
1 changed files with 3 additions and 1 deletions

View File

@ -379,7 +379,9 @@ function mark_admin_user_account {
}
function remove_instructions_from_motd {
sed -i '/## /d' /etc/motd
if grep -q "## " /etc/motd; then
sed -i '/## /d' /etc/motd
fi
}
function remove_default_user {