On June 5, 1967, the Six-Day War began. During the war, the UAR asked the Soviet Union for more arms, but the Soviet Union denied its request because it wanted the war to end. The war ended in the defeat of the UAR and Syria on June 10. Once the war was over, though, the Soviet Union was satisfied with the state of the Middle East and gave weapons to the Arabs in order to repair relations with them. For the Soviet Union, defeat meant that its position in the Middle East was impaired and its weapons and military training were given a poor reputation. Following this loss, Nasser agreed to allow the Soviets to keep military bases in the country.