original_string: public function processRedsysTransaction($ds_response, Transaction $transaction)
      {
          if ($ds_response > 99) {
              return false;
          }
  
          $transaction->setStatus(Transaction::STATUS_PAID);
          $pm = $this->manager->getRepository('EcommerceBundle:PaymentMethod')->findOneBySlug('redsys');
          $transaction->setPaymentMethod($pm);
  
          $this->manager->persist($transaction);
          $this->manager->flush();
  
          return true;
      }
code: public function processRedsysTransaction($ds_response, Transaction $transaction)
      {
          if ($ds_response > 99) {
              return false;
          }
  
          $transaction->setStatus(Transaction::STATUS_PAID);
          $pm = $this->manager->getRepository('EcommerceBundle:PaymentMethod')->findOneBySlug('redsys');
          $transaction->setPaymentMethod($pm);
  
          $this->manager->persist($transaction);
          $this->manager->flush();
  
          return true;
      }
code_tokens: public function processRedsysTransaction ( $ ds_response , Transaction $ transaction ) { if ( $ ds_response > 99 ) { return false ; } $ transaction -> setStatus ( Transaction :: STATUS_PAID ) ; $ pm = $ this -> manager -> getRepository ( 'EcommerceBundle:PaymentMethod' ) -> findOneBySlug ( 'redsys' ) ; $ transaction -> setPaymentMethod ( $ pm ) ; $ this -> manager -> persist ( $ transaction ) ; $ this -> manager -> flush ( ) ; return true ; }
docstring: Process a redsys transaction
  
  @param int                   $ds_response
  @param Transaction                 $transaction
  
  @return boolean
docstring_tokens: Process a redsys transaction