Fixed various bugs in preparation for my demonstration tomorrow.