Am 16.03.21 um 15:02 schrieb Dominik Csapak:
series looks good to me, the only thing that might be not ideal
is the value.replace('WARNINGS', '') call. it seems very brittle
though in reality it will probably not be a problem
Reviewed-By: Dominik Csapak <d.csa...@proxmox.com>
Thanks for the review. I'm also not 100% happy with the replace. I
didn't see a better alternative at the time, but maybe I do now:
We need to keep backwards compatibility for the existing callers of
parse_task_status(), so also returning the number of warnings there
doesn't seem to work. Instead, we could add a new
parse_task_status_full() that returns both the status *and* the text to
be displayed.
A better version of the replace would also be possible:
value.replace('WARNINGS', Proxmox.Utils.warningsText);
If one of those sounds sensible, I'll send a v2.
_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel