summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLiran Tal <liran.tal@gmail.com>2022-07-29 23:40:00 +0300
committerGitHub <noreply@github.com>2022-07-29 23:40:00 +0300
commit0b0c0c837a49ded4f5f4fa7dc60938b4e9e655ce (patch)
tree69c11741892066ba39e0f43b2d2084b8ac003306
parentce8d1e32795360399f169082efebc300bde56288 (diff)
fix: strip crlf to ensure it doesn't break the table layout (#207)v3.22.1
-rw-r--r--widgets/containers/containerList.widget.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/widgets/containers/containerList.widget.js b/widgets/containers/containerList.widget.js
index 0181a46..de46ba9 100644
--- a/widgets/containers/containerList.widget.js
+++ b/widgets/containers/containerList.widget.js
@@ -64,7 +64,8 @@ class myWidget extends ListWidget {
container.Id.substring(0, 5),
container.Names[0].substring(0, 40),
container.Image.substring(0, 35),
- container.Command.substring(0, 30),
+ // remove any new lines or carriage return line feed from the string in container.Command
+ container.Command.substring(0, 30).replace(/(\r\n|\n|\r)/gm, ''),
container.State,
container.Status
]