Find the word definition

Wiktionary
take the rap

vb. (context slang English) To be blamed or punished for something, especially for the wrongful actions of another; to willingly allow oneself to be so blamed or punished.