fixes php notice if attribute 'value' is not set or has been removed