all: Fix check for empty string (#8456)
Co-authored-by: deepsource-autofix[bot] <62050782+deepsource-autofix[bot]@users.noreply.github.com>
This commit is contained in:
co-authored by
deepsource-autofix[bot] <62050782+deepsource-autofix[bot]@users.noreply.github.com>
parent
a2c5d901f2
commit
80ec4acb53
+1
-1
@@ -55,7 +55,7 @@ func WindowsInvalidFilename(name string) error {
|
||||
// None of the path components should end in space or period, or be a
|
||||
// reserved name.
|
||||
for _, part := range strings.Split(name, `\`) {
|
||||
if len(part) == 0 {
|
||||
if part == "" {
|
||||
continue
|
||||
}
|
||||
switch part[len(part)-1] {
|
||||
|
||||
Reference in New Issue
Block a user