Fixins

fixes for #853, #821, #841, #854