We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
&.
1 parent e66a93a commit 4f178e0Copy full SHA for 4f178e0
README.adoc
@@ -351,6 +351,20 @@ class User
351
end
352
user&.zip
353
----
354
+
355
+=== Long safe navigation chain [[long-safe-navigation-chain]]
356
357
+Avoid `&.` chains longer than two.
358
359
+[source,ruby]
360
+----
361
+# bad
362
+user&.address&.zip
363
364
+# good
365
+user.address.zip if user
366
367
368
=== Spaces and Braces [[spaces-braces]]
369
370
No spaces after `(`, `[` or before `]`, `)`.
0 commit comments