Fixes to issues