$isPremium = false;
// check that the class exists and is loadable
if (XenForo_Application::autoload('EWRmedio_Model_Premium'))
{
// attempt to instantiate the model
$model = @XenForo_Model::create('EWRmedio_Model_Premium');
// check that the instantiated model is an extended XenForo_Model
$isPremium = is_a($model, 'XenForo_Model');
}