コード例 #1
0
ファイル: Driver.php プロジェクト: jubinpatel/horde
 /**
  * Delete a device from the backend.
  *
  * This method is intended to be overridden by a child class.  However it
  * also implements some basic checks, so a typical backend will still
  * call this method via parent::
  *
  * @param <type> $account
  * @param <type> $devid
  */
 public function deleteDevice($account, $devid)
 {
     if (empty($account) || empty($devid)) {
         throw new Shout_Exception(_("Invalid device."));
     }
     if (!Shout::checkRights("shout:accounts:{$account}:devices", PERMS_DELETE, 1)) {
         throw new Shout_Exception(_("Permission denied to delete devices in this account."));
     }
 }