It was for the Plot
It’s a positive outlook for when something does not go right. For example, your tour bus gets stuck in the sand – it was for the plot. You rent a car and make a wrong turn and end up somewhere you didn’t plan to – it was for the plot