Fixes and improvements after review