Appeal from a judgment of the Monroe County Court (Alex R. Renzi, J.), rendered July 5, 2006. The judgment convicted defendant, upon his plea of guilty, of assault in the second degree.
*1433It is hereby ordered that the judgment so appealed from is unanimously modified as a matter of discretion in the interest of justice and on the law by vacating the sentence and as modified the judgment is affirmed, and the matter is remitted to Monroe County Court for further proceedings in accordance with the following memorandum: On appeal from a judgment convicting him upon his plea of guilty of assault in the second degree (Penal Law § 120.05 [4]), defendant contends that County Court erred in ordering restitution inasmuch as it was not part of the plea agreement. We agree. Although defendant failed to preserve that contention for our review (see People v Cooke, 21 AD3d 1339 [2005]), we nevertheless exercise our power to review it as a matter of discretion in the interest of justice (see CPL 470.15 [6] [a]), and we conclude that the court should have afforded defendant the opportunity to withdraw his plea before ordering him to pay restitution (see Cooke, 21 AD3d 1339 [2005]). We therefore modify the judgment by vacating the sentence, and we remit the matter to County Court to impose the promised sentence or to afford defendant the opportunity to withdraw his plea. Present—Hurlbutt, J.P, Fahey, Peradotto, Green and Pine, JJ.