'Abd Allah Ibn al-'Abbās, never ate the flesh of an animal killed by a black man. Blacks, he said, are hideous creatures. I was told, adds al-Mas'ūdī, that Caliph Abū al-'Abbās al-Rādī bi-Allah, son of al-Muqtadir, never accepted anything from the hand of a black man. He said that they were disgusting slaves. I do not know if, by acting in this way, he was following the example of Ṭāwus or if he was conforming to particular rites (al-Mas'ūdī, 1973, vol. I, pp. 82-83).  
To break the stranglehold of conformity, we had to wait until the middle of the fourteenth century. It is in the work of Ibn Khaldūn, a philosopher and scholar from the Maghreb, that we see the emergence of a new scholarly mindset. He tried to tackle, in his own way, the thought processes of the past and its insane excesses:  
Genealogists, who know nothing about the nature of things, he explains, have imagined that blacks [...] are the sons of Hām [...], sons of Nūḥ and that the curse placed on them by the latter is the reason for the darkness of Hām's skin and the slavery that was subjected on his descendants by God. Now the Pentateuch only says that Nūḥ curses his son Hām and nowhere is there mention of his skin colour. The curse only made the sons of Hām slaves of the descendants of his brothers. To attribute the skin colour of black people to their being sons of Hām is to ignore the true nature of heat and cold and their impact on climate and creatures. The dark skin of inhabitants in these two parts of the world result from climactic conditions, that is to say, the increasingly hot sun of the south (Ibn Khaldūn, n.d., p. 83).  
The problem Ibn Khaldūn has is that he cannot completely get rid of the alleged theory of humours and ancient stereotypes, nodding to the inferiority, inconstancy and extreme emotivity of blacks (Ibn Khaldūn, n.d., p. 86).