Re-basing #92 and fixing #318