Fix mistakes in reader