Typing errors fixed