From 193c2bba13c278ca858862ca6db99e9e9ac29ce2 Mon Sep 17 00:00:00 2001 From: Andrew McMillan Date: Sat, 25 Sep 2010 22:26:43 +1200 Subject: [PATCH] Make 412 error response consistent with PUT-vcard. --- inc/caldav-PUT.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/caldav-PUT.php b/inc/caldav-PUT.php index dba5df1e..3f783b68 100644 --- a/inc/caldav-PUT.php +++ b/inc/caldav-PUT.php @@ -73,7 +73,7 @@ if ( $dav_resource->Exists() ) { * entity exists, the server MUST NOT perform the requested method, and * MUST return a 412 (Precondition Failed) response. */ - $request->PreconditionFailed(412,'if-match', translate( 'Existing resource does not match "If-Match" header - not accepted.')); + $request->PreconditionFailed(412,'if-match',sprintf('Existing resource ETag of "%s" does not match "%s"', $dav_resource->unique_tag(), $request->etag_if_match) ); } else if ( isset($request->etag_none_match) && $request->etag_none_match != '' && ($request->etag_none_match == $dav_resource->unique_tag() || $request->etag_none_match == '*') ) {