Some fixes, comments
Some fixes, added comments