Permalink
Browse files

Added explanation of `and` vs `&&` rule

  • Loading branch information...
1 parent 6dbfd96 commit 24db39885f5c98c85500c858e4b56a68329a3ca0 @bradwright bradwright committed Mar 14, 2013
Showing with 2 additions and 0 deletions.
  1. +2 −0 ruby.md
View
@@ -163,6 +163,8 @@
Do not use `and`/`or` if the left-hand side of the expression is more
complicated than a simple method call. Consider in the case above
whether the exception could better be handled in save_changes.
+
+ [Explanation of the difference between `&&` and `and`](http://blog.tinfoilsecurity.com/ruby-demystified-and-vs)
- Avoid multi-line `?:` (the ternary operator), use `if/unless`
instead.

0 comments on commit 24db398

Please sign in to comment.