<?php

class Plugin_Cms_User {

  public static function getUserGroup($user = NULL){
    if(empty($user)){
      // get the logged user
      $user = Pampa_Auth_Cms::getInstance()->getIdentity();
    }

    $modelCmsUsersGroups = new Model_Cms_UsersGroups();
    $usergroup = $modelCmsUsersGroups->find($user->usergroup_id)->current();

    return $usergroup;
  }

}