refactored logger to support array values out of the box.

fixes #3245, #3244
fixes display of array log messages in debug toolbar

fixes #3244