Fixed some issues with database update messages in admin.
authorChuck Scott <cscott@gaslightmedia.com>
Thu, 6 Apr 2017 18:00:04 +0000 (14:00 -0400)
committerChuck Scott <cscott@gaslightmedia.com>
Thu, 6 Apr 2017 18:00:04 +0000 (14:00 -0400)
index.php

index be39b89..e955f14 100644 (file)
--- a/index.php
+++ b/index.php
@@ -606,12 +606,6 @@ function glmCheckDatabase ()
                 // Include an admin message that we're updating the database
                 $startupNotices .= '<p>The '.$a['name'].' database tables require updating...</p>';
 
-                // Check if current glmMembersDatabaseDbVersion is invalid
-                if (!in_array($a['database']['dbCurrentVersion'], $a['database']['dbVersions'])) {
-                    $startupNotices .= '<p>The database version currently installed for this plugin is unknown. '
-                            .'Unable to install/update the '.$a['name'].' plugin.</p>';
-                }
-
                 // Traverse version list to find any required updates
                 $curVerFound = false;
                 $db_setup_status = true;
@@ -655,10 +649,10 @@ function glmCheckDatabase ()
                         // If there were no errors
                         if ($queryError == '') {
                             $startupNotices .= '<p>The database for the '.$a['name'].' plugin has been updated '
-                                    .'from V'.$dbVersion.'_V'.$ver.'.</p>';
+                                    .'from V'.$dbVersion.' to V'.$ver.'.</p>';
                         } else {
                             $startupNotices .= '<p>Failure updating the database tables for the '.$a['name'].' plugin '
-                                    .'from V'.$dbVersion.'_V'.$ver.'.</p>';
+                                    .'from V'.$dbVersion.' to V'.$ver.'.</p>';
                             $db_setup_status = false;
                             $startupNotices .= '<p>Database Update Error:</b> '.$queryError.'</p>';
                         }