updated type cast to interface