Fixes a few outstanding issues