mirror of
https://github.com/ragestudio/relic.git
synced 2025-06-09 10:34:18 +00:00
handle undefined data
This commit is contained in:
parent
84030da722
commit
42f3944e20
@ -5,6 +5,16 @@ import { Icons } from "components/Icons"
|
|||||||
import "./index.less"
|
import "./index.less"
|
||||||
|
|
||||||
const PackageUpdateAvailable = ({ update, close }) => {
|
const PackageUpdateAvailable = ({ update, close }) => {
|
||||||
|
if (!update) {
|
||||||
|
setTimeout(() => {
|
||||||
|
close()
|
||||||
|
}, 1000)
|
||||||
|
|
||||||
|
return <h1>
|
||||||
|
Nothing to update
|
||||||
|
</h1>
|
||||||
|
}
|
||||||
|
|
||||||
function handleUpdate() {
|
function handleUpdate() {
|
||||||
ipc.exec("pkg:update", update.manifest.id, {
|
ipc.exec("pkg:update", update.manifest.id, {
|
||||||
execOnFinish: true
|
execOnFinish: true
|
||||||
|
Loading…
x
Reference in New Issue
Block a user