Fixes "Trying to get property of non-object" when trying to lookup a mod...

...ule somewhere in the code when the module isn't installed/found in the database.

An example of this is the "forums" module, which tries to look up the "messaging" module to check if it's installed or not.