[API] Prevented errors with deleted products in the orders endpoint, closes #6813