提交 ef273847 编写于 作者: X Xavier Noria

Revert "Small edit to the if statement simplification for blank? on the Object...

Revert "Small edit to the if statement simplification for blank? on the Object class. An Object doesn't need to be nil and empty to be blank? just one or the other."

Reason: the original code is correct, see

    !nil && !empty -> !(nil || empty) -> !blank

That said, this example has too many negations
for my linking. Think should be revised to be
more positive and straightforward to read.

This reverts commit a4b6e3d9.
上级 a4b6e3d9
......@@ -4,7 +4,7 @@ class Object
#
# This simplifies:
#
# if !address.nil? || !address.empty?
# if !address.nil? && !address.empty?
#
# ...to:
#
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册