Two small bugs corrected