A few fixes to get it working.. but basic functionality is there