bugfix: NPE when setting a null value