Fixed some stuff from the merge of doom.