diff --git a/README.adoc b/README.adoc index ddbe750a..8187245a 100644 --- a/README.adoc +++ b/README.adoc @@ -333,17 +333,17 @@ E.g. if users are guaranteed to have an address and addresses are guaranteed to # bad user&.address&.zip -#good +# good user && user.address.zip ---- If such a change introduces excessive conditional logic, consider other approaches, such as delegation: [source, ruby] ---- -#bad +# bad user && user.address && user.address.zip -#good +# good class User def zip address&.zip @@ -376,11 +376,11 @@ Whichever one you pick - apply it consistently. [source,ruby] ---- +# bad - no space after { and before } +{one: 1, two: 2} + # good - space after { and before } { one: 1, two: 2 } - -# good - no space after { and before } -{one: 1, two: 2} ---- With interpolated expressions, there should be no padded-spacing inside the braces.