Hitler wanted to go to war against the Soviet Union, but not against the Western democracies. From his perspective, any Lebensraum he wanted could be found to the east of Germany. On the other hand, any western war would pit Germany against the massive industrial potential of Britain and the United States.
In 1939, dishonest French and British politicians promised that France would launch a general offensive against Germany if Poland was attacked. In 1939, Polish leaders naively based their entire foreign policy on that false promise. They adopted a strongly anti-German foreign policy.
Suppose instead that France had never made such promises to Poland; or that Poland’s leaders had been astute enough to recognize those promises for the pack of lies they were. Poland’s leaders would then have realized they would have had no choice but to seek friendly relations with either their eastern or western neighbor. Presumably this would have meant friendly relations with Germany, because Stalin wanted all of Poland east of the Curzon line. (Over half of Poland’s prewar territory.)
Friendly, or at least relatively neutral, relations between Germany and Poland would have given the Western democracies no excuse to intervene. The nations of Eastern Europe would have gradually fallen into either the German or Soviet spheres. Eventually, Germany and the Soviet Union would have gone to war against each other. A Nazi-Soviet war was probably unavoidable. But it need not have become a world war; and the Western democracies need not have intervened on the Soviet Union’s behalf.