Fixed typesaftey violation