mirror of
https://github.com/ansible/awx.git
synced 2026-03-26 21:35:01 -02:30
Fix for host events viewer
the host events had logic that was expecting to act on an array, but was not receiving an array
This commit is contained in:
@@ -497,6 +497,9 @@ export default
|
|||||||
// only show cmd if it's a cmd that was run
|
// only show cmd if it's a cmd that was run
|
||||||
if (!EventsViewerForm.fields[key] && obj[key].length > 0) {
|
if (!EventsViewerForm.fields[key] && obj[key].length > 0) {
|
||||||
// include the label head Shell Command instead of CMD in the modal
|
// include the label head Shell Command instead of CMD in the modal
|
||||||
|
if(typeof(obj[key]) === 'string'){
|
||||||
|
obj[key] = [obj[key]];
|
||||||
|
}
|
||||||
string_cmd += obj[key].join(" ");
|
string_cmd += obj[key].join(" ");
|
||||||
h = parseItem(string_cmd, key, "Shell Command");
|
h = parseItem(string_cmd, key, "Shell Command");
|
||||||
if (h) {
|
if (h) {
|
||||||
@@ -506,6 +509,9 @@ export default
|
|||||||
}
|
}
|
||||||
} else if (key === 'warnings') {
|
} else if (key === 'warnings') {
|
||||||
if (!EventsViewerForm.fields[key] && obj[key].length > 0) {
|
if (!EventsViewerForm.fields[key] && obj[key].length > 0) {
|
||||||
|
if(typeof(obj[key]) === 'string'){
|
||||||
|
obj[key] = [obj[key]];
|
||||||
|
}
|
||||||
string_warnings += obj[key].join(" ");
|
string_warnings += obj[key].join(" ");
|
||||||
h = parseItem(string_warnings, key, "Warnings");
|
h = parseItem(string_warnings, key, "Warnings");
|
||||||
if (h) {
|
if (h) {
|
||||||
|
|||||||
Reference in New Issue
Block a user