B #5419: fix condition error (#1311)

Co-authored-by: Jorge Lobo <jlobo@opennebula.systems>
(cherry picked from commit 28d6a21eee)
This commit is contained in:
Jorge Miguel Lobo Escalona authored and Tino Vazquez committed 2021-06-17 11:44:43 +02:00
1 parent 7cc518c9a6
commit 92db7cc4a8
1 file changed
+1 -2
@@ -297,8 +297,7 @@ const executeCommand = (command = '', resource = '', options = {}) => {
if (execute) {
if (execute.stdout) {
rtn = { success: true, data: execute.stdout.toString() }
}
if (execute.stderr && execute.stderr.length > 0) {
} else if (execute.stderr && execute.stderr.length > 0) {
rtn = { success: false, data: execute.stderr.toString() }
messageTerminal(defaultError(execute.stderr.toString(), 'Error command: %s'))
}