From 97ef22c2d3a9e50283264b8d8bb71dde732f975d Mon Sep 17 00:00:00 2001
From: Zoltan Runyo <zoltan.runyo@ess.eu>
Date: Mon, 21 Mar 2022 16:57:51 +0100
Subject: [PATCH] ICSHWI-8790: Disable the Deploy button on the 'Deploy dialog'
 when 'host' or 'Git reference' fields are empty

---
 src/components/IOC/IOCDeployDialog.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/components/IOC/IOCDeployDialog.js b/src/components/IOC/IOCDeployDialog.js
index 17e8ef09..2a95d5ff 100644
--- a/src/components/IOC/IOCDeployDialog.js
+++ b/src/components/IOC/IOCDeployDialog.js
@@ -99,7 +99,7 @@ export function IOCDeployDialog({ open, setOpen, submitCallback, hasActiveDeploy
         </DialogContent>
         <DialogActions>
           <Button onClick={handleClose} color="primary">Cancel</Button>
-          <Button color="primary" variant="contained" type="submit" disabled={hasActiveDeployment && init?.version === gitVersion}>Deploy</Button>
+          <Button color="primary" variant="contained" type="submit" disabled={!host || !gitVersion || (hasActiveDeployment && init?.version === gitVersion)}>Deploy</Button>
         </DialogActions>
       </form>
     </Dialog>
-- 
GitLab