Corrects some kind of type and incorrect behaviour