mirror of https://github.com/jetkvm/kvm.git
fix(ui): shouldn't pass custom version to onConfirmCustomUpdate if not available
This commit is contained in:
parent
3fab951d43
commit
0cc84f0c54
|
|
@ -101,10 +101,9 @@ export function Dialog({
|
|||
const { modalView, setModalView, otaState } = useUpdateStore();
|
||||
const forceCustomUpdate = customSystemVersion !== undefined || customAppVersion !== undefined;
|
||||
const onConfirmCustomUpdate = useCallback(() => {
|
||||
console.debug("onConfirmCustomUpdate", customAppVersion, customSystemVersion, versionInfo);
|
||||
onConfirmCustomUpdateCallback(
|
||||
customAppVersion !== undefined ? customAppVersion : versionInfo?.remote?.appVersion,
|
||||
customSystemVersion !== undefined ? customSystemVersion : versionInfo?.remote?.systemVersion,
|
||||
customAppVersion !== undefined ? versionInfo?.remote?.appVersion : undefined,
|
||||
customSystemVersion !== undefined ? versionInfo?.remote?.systemVersion : undefined,
|
||||
);
|
||||
}, [onConfirmCustomUpdateCallback, customAppVersion, customSystemVersion, versionInfo]);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue