From 37b29231e47a0c4458dc1c15d98588f16f07e1e2 Mon Sep 17 00:00:00 2001
From: Marius Cramer <m.cramer@pixcept.de>
Date: Thu, 06 Aug 2015 03:18:44 -0400
Subject: [PATCH] - don't set password via remoting if field is empty

---
 interface/web/sites/aps_installedpackages_list.php |    6 +-----
 1 files changed, 1 insertions(+), 5 deletions(-)

diff --git a/interface/web/sites/aps_installedpackages_list.php b/interface/web/sites/aps_installedpackages_list.php
index 418cc43..f323a9c 100644
--- a/interface/web/sites/aps_installedpackages_list.php
+++ b/interface/web/sites/aps_installedpackages_list.php
@@ -51,7 +51,7 @@
 $is_admin = ($_SESSION['s']['user']['typ'] == 'admin') ? true : false;
 if(!$is_admin)
 {
-	$cid = $app->db->queryOneRecord('SELECT client_id FROM client WHERE username = "'.$app->db->quote($_SESSION['s']['user']['username']).'";');
+	$cid = $app->db->queryOneRecord('SELECT client_id FROM client WHERE username = ?', $_SESSION['s']['user']['username']);
 	//$client_ext = ' AND aps_instances.customer_id = '.$cid['client_id'];
 	$client_ext = ' AND '.$app->tform->getAuthSQL('r', 'aps_instances');
 }
@@ -125,10 +125,6 @@
 		else $ils = $rec['install_location'];
 		$rec['install_location_short'] = $ils;
 
-		// Also set a boolean-like variable for the reinstall button (vlibTemplate doesn't allow variable comparisons)
-		// For a reinstall, the package must be already installed successfully and (still be) enabled
-		if($rec['instance_status'] == INSTANCE_SUCCESS && $rec['package_status'] == PACKAGE_ENABLED)
-			$rec['reinstall_possible'] = 'true';
 		// Of course an instance can only then be removed when it's not already tagged for removal
 		if($rec['instance_status'] != INSTANCE_REMOVE && $rec['instance_status'] != INSTANCE_INSTALL)
 			$rec['delete_possible'] = 'true';

--
Gitblit v1.9.1