Fixes! Also, refactor to accomodate said fixes.