bugfix for undefined field