From 7f728551de4fc060f39e1282cde3afa88f9ba23a Mon Sep 17 00:00:00 2001 From: dongsheng Date: Fri, 3 Apr 2009 02:16:48 +0000 Subject: [PATCH] "MDL-17475, if webdav_server is empty, return null" --- repository/webdav/repository.class.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/repository/webdav/repository.class.php b/repository/webdav/repository.class.php index ed959540fa..cbd9158ea5 100644 --- a/repository/webdav/repository.class.php +++ b/repository/webdav/repository.class.php @@ -13,6 +13,9 @@ class repository_webdav extends repository { public function __construct($repositoryid, $context = SITEID, $options = array()) { parent::__construct($repositoryid, $context, $options); $this->wd = new webdav_client(); + if (empty($this->webdav_server)) { + return; + } $this->wd->set_server($this->webdav_server); if (empty($this->webdav_port)) { $this->wd->set_port(80); -- 2.39.5