Bunch of fixes from the polishing phase