[pve-devel] [PATCH pve-manager] fix #4228: Display warning when user rollbacks a running container.

Thomas Lamprecht t.lamprecht at proxmox.com
Wed Sep 7 10:07:36 CEST 2022


Am 07/09/2022 um 09:59 schrieb Thomas Lamprecht:
> Why not differ just between running and not, ignoring the type, e.g. something like
> 
> let warning = isRunning
>     ? gettext("The guest is currently running and will be stopped!")
>     : gettext("Current state will be lost.")

Send a bit to early, it would be naturally better to just add both

let warning = gettext("Current state will be lost!");
if (isRunning) {
    warning += '<br>' + gettext("The guest is currently running and will be stopped!");
}

ps./nit: <br> tag only needs a / in xhtml documents, but not html5 and while we have
a bit of a mixed usage we prefer to use the shorter for new things.





More information about the pve-devel mailing list