From 0a435d4f2274d0ec8cae0094f0463d78fe664859 Mon Sep 17 00:00:00 2001 From: Andrew McMillan Date: Mon, 10 Sep 2012 13:07:49 +1200 Subject: [PATCH] Fix debugging to error log. --- inc/DAVResource.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/inc/DAVResource.php b/inc/DAVResource.php index 4294b361..6f3a5dbf 100644 --- a/inc/DAVResource.php +++ b/inc/DAVResource.php @@ -1289,7 +1289,7 @@ EOQRY; * Returns the current sync_token for this collection, or the containing collection */ function sync_token( $cachedOK = true ) { - printf("Request for a%scached sync-token\n", ($cachedOK ? ' ' : 'n un') ); + dbg_error_log('DAVResource', 'Request for a%scached sync-token', ($cachedOK ? ' ' : 'n un') ); if ( $this->IsPrincipal() ) return null; if ( $this->collection_id() == 0 ) return null; if ( !isset($this->sync_token) || !$cachedOK ) { @@ -1302,7 +1302,7 @@ EOQRY; } $this->sync_token = 'data:,'.$row->sync_token; } - printf("Returning sync token of '%s'\n", $this->sync_token ); + dbg_error_log('DAVResource', 'Returning sync token of "%s"', $this->sync_token ); return $this->sync_token; } @@ -1450,6 +1450,7 @@ EOQRY; case 'dav-data': if ( !isset($this->resource) ) $this->FetchResource(); + trace_bug("Exists ".($this->exists?"true":"false")); return $this->resource->caldav_data; break;