[AppDB] Adjustments to handling of deleted distributions
Rosanne DiMesio
dimesio at earthlink.net
Tue Jul 25 08:08:09 CDT 2017
Excludes deleted distributions from the check for duplicates
and sets Unknown as the name to display for test reports
with a deleted distribution.
Signed-off-by: Rosanne DiMesio <dimesio at earthlink.net>
---
include/distribution.php | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/include/distribution.php b/include/distribution.php
index a6e9d27..40eeb7c 100644
--- a/include/distribution.php
+++ b/include/distribution.php
@@ -25,6 +25,7 @@ class distribution {
return;
// We fetch the data related to this distribution.
+ $this->sName = "Unknown";
if(!$oRow)
{
$sQuery = "SELECT *
@@ -92,7 +93,8 @@ class distribution {
//Let's not create a duplicate
$sQuery = "SELECT *
FROM distributions
- WHERE name = '?'";
+ WHERE name = '?'
+ AND state != 'deleted'";
$hResult = query_parameters($sQuery, $this->sName);
if($hResult && $oRow = query_fetch_object($hResult))
--
2.12.3
More information about the wine-patches
mailing list