removed obsolete type cast
removed obsolete function