public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: Matthias Heiserer <m.heiserer@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH v3 widget-toolkit 1/2] ui: SMART: fix eslint error / show correct value
Date: Fri, 24 Feb 2023 15:40:45 +0100	[thread overview]
Message-ID: <20230224144046.365795-1-m.heiserer@proxmox.com> (raw)

Signed-off-by: Matthias Heiserer <m.heiserer@proxmox.com>
---

Changes from v2:
Calculate the field in a different way...

Thanks to dominik for simplifying/fixing the logic!

 src/window/DiskSmart.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/window/DiskSmart.js b/src/window/DiskSmart.js
index b538ea1..3824175 100644
--- a/src/window/DiskSmart.js
+++ b/src/window/DiskSmart.js
@@ -159,12 +159,12 @@ Ext.define('Proxmox.window.DiskSmart', {
 	    {
 		name: 'real-value',
 		// FIXME remove with next major release (PBS 3.0)
-		calculate: data => (data.normalized ?? false) ? data.raw : data.value,
+		calculate: data => data.raw ?? data.value,
 	    },
 	    {
 		name: 'real-normalized',
 		// FIXME remove with next major release (PBS 3.0)
-		calculate: data => data.normalized ?? data.raw,
+		calculate: data => data.normalized ?? data.value,
 	    },
 	],
 	idProperty: 'name',
-- 
2.30.2





             reply	other threads:[~2023-02-24 14:40 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-24 14:40 Matthias Heiserer [this message]
2023-02-24 14:40 ` [pve-devel] [PATCH v3 widget-toolkit 2/2] ui: SMART: rename Value to Raw Value Matthias Heiserer
2023-03-14 14:27 ` [pve-devel] applied: [PATCH v3 widget-toolkit 1/2] ui: SMART: fix eslint error / show correct value Thomas Lamprecht

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230224144046.365795-1-m.heiserer@proxmox.com \
    --to=m.heiserer@proxmox.com \
    --cc=pve-devel@lists.proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal