Minor naming error and typecasts