Why did Douglass’ views on immigrants contradict the general views that most white Americans held in the years after the Civil War?

For the paper, please analyze and interpret the speech delivered in Boston in 1869 by Frederick Douglass titled “The Composite Nation” in Foner, Voices of Freedom.
In the mid-nineteenth century thousand of immigrants from China came to the United States every year. Most worked low-wage jobs which white Americans refused to do, especially the railroads. But by 1869 (the year of Douglass’s speech) railroad jobs became fewer and Chinese workers went to cities such as San Francisco and Los Angeles to seek work. Competing with white laborers aggravated racial tensions and led to a series of race riots.