Cook someone’s goose

Meaning: To spoil someone’s plans or chances of success.

Example: The discovery of the error cooked the company’s goose.