Changeset 305


Ignore:
Timestamp:
02/26/10 10:23:56 (10 years ago)
Author:
sander
Message:

Properly redirect when a request fails to queue

Location:
trunk/server/www
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/server/www/app/controllers/requests_controller.php

    r295 r305  
    239239                        // Queue the preprocessor 
    240240                        if (!$this->Request->defer('run', 'Preprocessor')) { 
    241                                 $errors[] = __('Failed to queue the request for the virus scanner. Please contact system administration.', true); 
     241                                $this->Request->delete(); 
     242                                $this->Session->setFlash(__('Failed to queue the request for the virus scanner. Please contact system administration.', true)); 
     243                                $this->redirect(array('action'=>'add')); 
    242244                        } 
    243245 
  • trunk/server/www/cake/libs/model/model.php

    r5 r305  
    16611661                if (!empty($id)) { 
    16621662                        $this->id = $id; 
     1663                        $this->exists(true); 
    16631664                } 
    16641665                $id = $this->id; 
Note: See TracChangeset for help on using the changeset viewer.