updated read_data