DISQUS

DISQUS Hello! A Noted Path by Theodore Nguyen-Cao is using DISQUS, a powerful comment system, to manage its comments. Learn more.

Community Page

A Noted Path by Theodore Nguyen-Cao

Personal blog of Theodore Nguyen-Cao
Jump to original thread »
Author

Ruby: ! versus not operator

Started by Theo · 12 months ago

I was writing some code in an erb template that looked like this:
<% if @user && not @user.errors.empty? -%>

#do stuff

<% end -%>

This resulted in a syntax error. Huh? What’s wrong with this?

Turns out it’s an outstanding Core Ruby bug.

As shown in the ticket if we have a method ... Continue reading »

0 comments

This thread has no comments yet.

Add New Comment

Returning? Login