Some more typing not fully correct though