Humour comes from many things, such as racism. That Pepe frog is clearly not meant to be serious and that's why it's funny.
When someone is sincere, that's when the problem arises. However, there should never be a hold on speech, even if it's racist or offensive.