diff --git a/Controller/OpauthAppController.php b/Controller/OpauthAppController.php index e3afd46..5ad9b2e 100644 --- a/Controller/OpauthAppController.php +++ b/Controller/OpauthAppController.php @@ -136,6 +136,9 @@ protected function _loadOpauth($config = null, $run = false){ } App::import('Vendor', 'Opauth.Opauth/lib/Opauth/Opauth'); + if (!class_exists('Opauth')) { + throw new CakeException('Unable to load Opauth class. [app/Plugin/Opauth/Vendor/Opauth] Did you load submodules?'); + } $this->Opauth = new Opauth( $config, $run ); } -} \ No newline at end of file +}