Changeset e6c7c3c in github


Ignore:
Timestamp:
Mar 13, 2007 6:53:26 PM (6 years ago)
Author:
thomascube <thomas@…>
Branches:
master, HEAD, courier-fix, dev-browser-capabilities, pdo, release-0.6, release-0.7, release-0.8
Children:
1c7b97e8
Parents:
6ce04b1
Message:

Fixed bugs in rcube_db and rcube_imap classes

Location:
program/include
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • program/include/rcube_db.inc

    r107bde9 re6c7c3c  
    294294      case 'pgsql': 
    295295        $result = &$this->db_handle->getOne("SELECT CURRVAL('$sequence')"); 
    296          
    297       case 'mssql': 
    298         $result = &$this->db_handle->getOne("SELECT @@IDENTITY"); 
    299  
    300296        if (DB::isError($result)) 
    301297          raise_error(array('code' => 500, 'type' => 'db', 'line' => __LINE__, 'file' => __FILE__,  
    302298                            'message' => $result->getMessage()), TRUE, FALSE); 
    303  
     299        return $result; 
     300 
     301      case 'mssql': 
     302        $result = &$this->db_handle->getOne("SELECT @@IDENTITY"); 
     303        if (DB::isError($result)) 
     304          raise_error(array('code' => 500, 'type' => 'db', 'line' => __LINE__, 'file' => __FILE__,  
     305                            'message' => $result->getMessage()), TRUE, FALSE); 
    304306        return $result; 
    305307                 
     
    309311      case 'mysqli': 
    310312        return mysqli_insert_id($this->db_handle->connection); 
    311          
     313 
    312314      case 'sqlite': 
    313315        return sqlite_last_insert_rowid($this->db_handle->connection); 
     
    359361  function _fetch_row($result, $mode) 
    360362    { 
    361     if (DB::isError($result)) 
     363    if (!$result || DB::isError($result)) 
    362364      { 
    363365      raise_error(array('code' => 500, 'type' => 'db', 'line' => __LINE__, 'file' => __FILE__, 
  • program/include/rcube_imap.inc

    r6ce04b1 re6c7c3c  
    879879      $results = array(); 
    880880      foreach ($criteria as $crit) 
    881         $results = array_merge($results, $this->search($mbox_name, $crit, $str, $charset)); 
     881        if ($search_result = $this->search($mbox_name, $crit, $str, $charset)) 
     882          $results = array_merge($results, $search_result); 
    882883       
    883884      $results = array_unique($results); 
Note: See TracChangeset for help on using the changeset viewer.