Misc fixes
Some fixes