Dialyzer races type fixes

Corrects a type declaration and cleans up some others.