src/CI_Base_Model.php
public function update($primary_value, $data)
    {
        $data = $this->_do_pre_update($data);

        if ($data !== FALSE)
        {
            $result = $this->_database->where($this->primary_key, $primary_value)
                ->set($data)
                ->update($this->_table);

            $this->trigger('after_update', array($data, $result));

            return $result;
        }
        else
        {
            return FALSE;
        }
    }
public function update($primary_value, $data)
    {
        $data = $this->_do_pre_update($data);

        if ($data !== FALSE)
        {
            $result = $this->_database->where($this->primary_key, $primary_value)
                ->set($data)
                ->update($this->_table);

            $this->trigger('after_update', array($data, $result));

            return $result;
        }
        else
        {
            return FALSE;
        }
    }
Updated a record based on the primary value.
@param $primary_value
@param $data
@return bool