From 2774ac4ca46874e974abb0c460139d81dc3a8254 Mon Sep 17 00:00:00 2001
From: LaKing <LaKing@ispconfig3>
Date: Mon, 02 May 2011 13:57:45 -0400
Subject: [PATCH] Update on Sites, adding the logs tab to see error logs.

---
 server/plugins-available/apache2_plugin.inc.php |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/server/plugins-available/apache2_plugin.inc.php b/server/plugins-available/apache2_plugin.inc.php
index de6a043..5011d5f 100644
--- a/server/plugins-available/apache2_plugin.inc.php
+++ b/server/plugins-available/apache2_plugin.inc.php
@@ -866,7 +866,7 @@
 
 		$vhost_file = escapeshellcmd($web_config['vhost_conf_dir'].'/'.$data['new']['domain'].'.vhost');
 		//* Make a backup copy of vhost file
-		copy($vhost_file,$vhost_file.'~');
+		if(file_exists($vhost_file)) copy($vhost_file,$vhost_file.'~');
 		
 		//* Write vhost file
 		file_put_contents($vhost_file,$tpl->grab());

--
Gitblit v1.9.1