Fix previous commit by only searching for Model_*

This commit is contained in:
Deon George 2015-10-16 13:27:47 +11:00
parent 31b9d9b3e5
commit 6c5366d366

View File

@ -515,7 +515,7 @@ class Kohana_Core {
} }
// Enable finding a default Model // Enable finding a default Model
if ($path = Kohana::find_file($directory,'Model/DEFAULT')) { if (preg_match('/^Model_/',$class) AND $path = Kohana::find_file($directory,'Model/DEFAULT')) {
// Load the class file // Load the class file
require $path; require $path;