check if book has been already purchased before redirecting to paypal