mirror of
https://github.com/home-assistant/core.git
synced 2025-04-24 09:17:53 +00:00
Correct unit conversion for OneDrive quota display (#140337)
* Correct unit conversion for OneDrive quota display * Convert OneDrive quota values from bytes to GiB in coordinator and update strings
This commit is contained in:
parent
e0b030c892
commit
597540b611
@ -88,8 +88,8 @@ class OneDriveUpdateCoordinator(DataUpdateCoordinator[Drive]):
|
||||
),
|
||||
translation_key=key,
|
||||
translation_placeholders={
|
||||
"total": str(drive.quota.total),
|
||||
"used": str(drive.quota.used),
|
||||
"total": f"{drive.quota.total / (1024**3):.2f}",
|
||||
"used": f"{drive.quota.used / (1024**3):.2f}",
|
||||
},
|
||||
)
|
||||
return drive
|
||||
|
Loading…
x
Reference in New Issue
Block a user