fixed a few bugs
few more bugs