When you try logging something like:
logger.debug(“This won’t work: ” + @anarray)
you’ll get a syntax error:
TypeError (no implicit conversion of Array into String):
Instead use .inspect
e.g. this will work:
logger.debug(“This will work: ” + @anarray.inspect)
See also:
http://stackoverflow.com/questions/5196240/logger-debug-this-is-an-array-rails