]> git.giacomolli.uk - onechat/blobdiff - .golangci.yml
Separate returns from longer statement blocks
[onechat] / .golangci.yml
index bba6f25a3bcaf1190b09895e04be4d5af7fa99af..d5f20b34c84d8c768e034c4a208863b5f741e3a5 100644 (file)
@@ -8,7 +8,11 @@ linters:
     - testifylint
     - revive
     - wrapcheck
+    - nlreturn
   settings:
+    nlreturn:
+      # go-code: Keep a short declaration with its immediate use.
+      block-size: 2
     wrapcheck:
       # go-code: Return ctx.Err() directly.
       extra-ignore-sigs: