mirror of
https://git.friendi.ca/friendica/friendica-addons.git
synced 2025-07-07 00:48:55 +00:00
Initial Release of the calendar plugin
This commit is contained in:
parent
45cc9885fc
commit
7115197a33
561 changed files with 189494 additions and 0 deletions
45
dav/SabreDAV/lib/Sabre/DAV/Exception/MethodNotAllowed.php
Normal file
45
dav/SabreDAV/lib/Sabre/DAV/Exception/MethodNotAllowed.php
Normal file
|
@ -0,0 +1,45 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* MethodNotAllowed
|
||||
*
|
||||
* The 405 is thrown when a client tried to create a directory on an already existing directory
|
||||
*
|
||||
* @package Sabre
|
||||
* @subpackage DAV
|
||||
* @copyright Copyright (C) 2007-2012 Rooftop Solutions. All rights reserved.
|
||||
* @author Evert Pot (http://www.rooftopsolutions.nl/)
|
||||
* @license http://code.google.com/p/sabredav/wiki/License Modified BSD License
|
||||
*/
|
||||
class Sabre_DAV_Exception_MethodNotAllowed extends Sabre_DAV_Exception {
|
||||
|
||||
/**
|
||||
* Returns the HTTP statuscode for this exception
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function getHTTPCode() {
|
||||
|
||||
return 405;
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* This method allows the exception to return any extra HTTP response headers.
|
||||
*
|
||||
* The headers must be returned as an array.
|
||||
*
|
||||
* @param Sabre_DAV_Server $server
|
||||
* @return array
|
||||
*/
|
||||
public function getHTTPHeaders(Sabre_DAV_Server $server) {
|
||||
|
||||
$methods = $server->getAllowedMethods($server->getRequestUri());
|
||||
|
||||
return array(
|
||||
'Allow' => strtoupper(implode(', ',$methods)),
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue