Show
Ignore:
Timestamp:
03/12/2008 11:27:31 AM (10 months ago)
Author:
Geert
Message:

Calling parent's constructor for Kohana_Exceptions

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/system/core/Kohana.php

    r2263 r2291  
    11681168                if ($message == $error) 
    11691169                { 
    1170                         $this->message .= $error; 
    1171                 } 
    1172                 else 
    1173                 { 
    1174                         $this->message = $message; 
    1175                 } 
     1170                        $message .= $error; 
     1171                } 
     1172 
     1173                // Sets $this->message the proper way 
     1174                parent::__construct($message); 
    11761175        } 
    11771176 
     
    12231222        public function __construct($title, $message, $template = FALSE) 
    12241223        { 
    1225                 $this->code     = $title; 
    1226                 $this->message  = $message; 
     1224                Exception::__construct($message); 
     1225 
     1226                $this->code = $title; 
    12271227 
    12281228                if ($template != FALSE) 
     
    12551255                } 
    12561256 
    1257                 $this->message = Kohana::lang('core.page_not_found', $page); 
    1258                 $this->file    = FALSE; 
    1259                 $this->line    = FALSE; 
     1257                Exception::__construct(Kohana::lang('core.page_not_found', $page)); 
     1258 
     1259                $this->file = FALSE; 
     1260                $this->line = FALSE; 
    12601261 
    12611262                $this->template = $template;