check type before passing to util.table_to_fields

This check is from code that is used in production. Without it, heka was crashing like so:

2014/08/29 04:46:20 Decoder 'FxaAuth-FxaAuthDecoder' error: FATAL: process_message() /usr/share/heka/lua_modules/util.lua:15: bad argument #1 to 'pairs' (table expected, got string)
2014/08/29 04:46:20 Shutdown initiated.