From 20fad80dffac7bb567ca84da75f6c7571024babe Mon Sep 17 00:00:00 2001 From: Simon Ser Date: Wed, 7 Feb 2024 17:26:50 +0100 Subject: [PATCH] carddav: return HTTP 501 error instead of panicing --- carddav/server.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/carddav/server.go b/carddav/server.go index bd893f4..028e151 100644 --- a/carddav/server.go +++ b/carddav/server.go @@ -720,11 +720,11 @@ func (b *backend) Mkcol(r *http.Request) error { } func (b *backend) Copy(r *http.Request, dest *internal.Href, recursive, overwrite bool) (created bool, err error) { - panic("TODO") + return false, internal.HTTPErrorf(http.StatusNotImplemented, "carddav: Copy not implemented") } func (b *backend) Move(r *http.Request, dest *internal.Href, overwrite bool) (created bool, err error) { - panic("TODO") + return false, internal.HTTPErrorf(http.StatusNotImplemented, "carddav: Move not implemented") } // https://tools.ietf.org/rfcmarkup?doc=6352#section-6.3.2.1