However, Stalin learned from Richard Sorge, a well-placed Soviet spy in Tokyo, that Japan would not invade Siberia, which [caused] the Soviet dictator to shift his elite Siberian troops from the Far East to Moscow, just in time to save the Soviet capital.
There seems to be a missing word which I have added in italics.
Militarily, the outcome of a 1941 Russo-Japanese war would have been far from certain. Russia had been defeated in the Russo-Japanese War of 1904–5, and during its intervention in the Russian Civil War, Japanese troops had advanced all the way to Lake Baikal. But closer to World War II, Russian tanks and artillery won the Khalkin Gol border battle in 1939, while the Red Army’s armored blitzkrieg smashed Japan’s Manchurian Kwantung Army in 1945. But a 1941 clash would have been interesting. The Japanese Army was not mechanized by Western and Soviet standards, putting them at a disadvantage against Soviet armor, while the logistics of supplying even a lightly equipped Japanese offensive into the Siberian wilderness would have been daunting.
The red phrase could say "closer in time to", but most English speakers would recognize that since the preceding sentences involved events at a certain date, the word closer refers to closer in time, not closer in distance.