Added an if else statement as a failsafe in case the id equals 0.