Updated some small logic, cleaned up some init code