fixed a few minor glitches