Skip to content
This repository has been archived by the owner on Aug 2, 2021. It is now read-only.

Commit

Permalink
Spare a little CPU resources
Browse files Browse the repository at this point in the history
Signed-off-by: Knut Ahlers <knut@ahlers.me>
  • Loading branch information
Luzifer committed Jan 3, 2020
1 parent 8b43a5d commit 2167e6f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion parser.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ func ParseSIIPlainFile(r io.Reader) (*Unit, error) {

return nil, errors.New("Unexpected closing braces")

case blockStartRegex.MatchString(line) && !inBlock:
case !inBlock && blockStartRegex.MatchString(line):
if !inUnit {
return nil, errors.New("Unexpected block start outside unit")
}
Expand Down

0 comments on commit 2167e6f

Please sign in to comment.