From 537dfe14e9bac723a35d4d6881a6931ab9f8a71b Mon Sep 17 00:00:00 2001 From: skeeter Date: Wed, 9 May 2001 03:21:14 +0000 Subject: [PATCH] Fixed the problem where calendar items were not being deleted. Tracked it down to a ->db overwrite problem where todo was using ->db and the deleteaccount.php page was using the same. --- calendar/inc/class.calendar_sql.inc.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/calendar/inc/class.calendar_sql.inc.php b/calendar/inc/class.calendar_sql.inc.php index 456b5466c5..7e6bdb2a0c 100755 --- a/calendar/inc/class.calendar_sql.inc.php +++ b/calendar/inc/class.calendar_sql.inc.php @@ -77,7 +77,7 @@ class calendar_ extends calendar__ function delete_calendar($stream='',$calendar='') { - $this->stream->query('SELECT cal_id FROM phpgw_cal WHERE owner='.$calendar,__LINE__,__FILE__); + $this->stream->query('SELECT cal_id FROM phpgw_cal WHERE owner='.intval($calendar),__LINE__,__FILE__); if($this->stream->num_rows()) { while($this->stream->next_record()) @@ -87,7 +87,7 @@ class calendar_ extends calendar__ $this->expunge($stream); } $this->stream->lock(array('phpgw_cal_user')); - $this->stream->query('DELETE FROM phpgw_cal_user WHERE cal_login='.$calendar,__LINE__,__FILE__); + $this->stream->query('DELETE FROM phpgw_cal_user WHERE cal_login='.intval($calendar),__LINE__,__FILE__); $this->stream->unlock(); return $calendar;