And God made good His promise to you when by His leave you were about to destroy your foes , but then your courage failed you and you disagreed among yourselves [ concerning the Prophet 's direction ] and disobeyed it , after He had brought you within sight of what you wished for , some of you desired the goods of this world and some of you desired the Hereafter , then in order that He might put you to the test , He prevented you from defeating your foes . But now He has pardoned you : God is most gracious to the believers .