adds handling for undefined data item