diff --git a/src/bb-library/Box/Mod.php b/src/bb-library/Box/Mod.php index 9147fdd81..91805a559 100644 --- a/src/bb-library/Box/Mod.php +++ b/src/bb-library/Box/Mod.php @@ -301,6 +301,11 @@ class Box_Mod private function _getModPath() { - return BB_PATH_MODS . DIRECTORY_SEPARATOR . ucfirst($this->mod) . DIRECTORY_SEPARATOR; + $modPath = BB_PATH_MODS . DIRECTORY_SEPARATOR . ucfirst($this->mod) . DIRECTORY_SEPARATOR; + if(is_dir($modPath)){ + return $modPath; + }else{ + throw new Box_Exception("Error: module $this->mod path appears to be invalid. Please ensure the module folder is named " . ucfirst($this->mod)); + } } }