Fixed bug Exception launched when it had no fields

Check if numFields is 0, set the fieldWidth to 0 instead of making a division with that number.
This way it avoids a division by zero.