Fixed some bad code.