From abdb4c4bf79e537f332ffef6a2c902551c88963f Mon Sep 17 00:00:00 2001 From: koalaman Date: Sat, 18 Jul 2015 10:02:55 -0700 Subject: [PATCH] Updated SC2157 (markdown) --- SC2157.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SC2157.md b/SC2157.md index 506c157..95ba391 100644 --- a/SC2157.md +++ b/SC2157.md @@ -16,7 +16,7 @@ ### Rationale: -Since `[ str ]` checks that the string is non-empty, the space inside the quotes in the problematic code causes the test to always be true. +Since `[ str ]` checks that the string is non-empty, the space inside the quotes in the problematic code causes the test to always be true, since a string with a space can not be empty. Sometimes this is also caused by overquoting an example, e.g. `[ "$foo -gt 0" ]`, which is always true for the same reason. The intention here was `[ "$foo" -gt 0 ]`.