Non-empty then clause Medium

In shell scripting, then clauses cannot be empty and must contain at least one command. To achieve a no-operation in such cases, it's recommended to use a dummy command like true, ensuring the script structure remains valid and functional.

Detector ID
shell/non-empty-then-clause@v1.0
Category
Common Weakness Enumeration (CWE) external icon
-
Tags
-