Changeset 2016

Show
Ignore:
Timestamp:
02/10/2008 12:23:51 AM (10 months ago)
Author:
Shadowhand
Message:

Cleaning up some small things in libraries and drivers. Also removed Form_Model and the media controller.

Location:
trunk/system
Files:
2 removed
3 modified

Legend:

Unmodified
Added
Removed
  • trunk/system/libraries/Archive.php

    r1924 r2016  
    6060 
    6161                // Set the name 
    62                 ($name === NULL) and $name = $path; 
     62                empty($name) and $name = $path; 
    6363 
    6464                if (file_exists($path) AND is_dir($path)) 
     
    7171                        $this->paths[] = array($path, $name); 
    7272 
    73                         if ($recursive == TRUE) 
     73                        if ($recursive === TRUE) 
    7474                        { 
    7575                                $dir = opendir($path); 
  • trunk/system/libraries/drivers/Database/Mysql.php

    r1931 r2016  
    289289        public function field_data($table) 
    290290        { 
    291                 $query  = mysql_query('SHOW COLUMNS FROM '.$this->escape_table($table), $this->link); 
    292  
    293                 $table  = array(); 
    294                 while ($row = mysql_fetch_object($query)) 
    295                 { 
    296                         $table[] = $row; 
    297                 } 
    298  
    299                 return $table; 
     291                $columns = array(); 
     292 
     293                if ($query = mysql_query('SHOW COLUMNS FROM '.$this->escape_table($table), $this->link)) 
     294                { 
     295                        if (mysql_num_rows($query) > 0) 
     296                        { 
     297                                while ($row = mysql_fetch_object($query)) 
     298                                { 
     299                                        $columns[] = $row; 
     300                                } 
     301                        } 
     302                } 
     303 
     304                return $columns; 
    300305        } 
    301306 
  • trunk/system/libraries/drivers/Database/Pdosqlite.php

    r1906 r2016  
    661661        } 
    662662        // End Interface 
     663 
    663664} // End PdoSqlite_Result Class