Compare the names as both lower case strings
authorSteve Sutton <steve@gaslightmedia.com>
Tue, 25 Apr 2017 16:26:06 +0000 (12:26 -0400)
committerSteve Sutton <steve@gaslightmedia.com>
Tue, 25 Apr 2017 16:26:06 +0000 (12:26 -0400)
For the Event Category check in the icalFeedImport script need to
compare the category name with lower casing both fields to find the
correct category.

models/front/events/icalFeedImport.php

index 532b430..70e064d 100644 (file)
@@ -45,8 +45,8 @@ class GlmMembersFront_events_icalFeedImport
             $this->wpdb->prepare(
                 "SELECT id
                    FROM " . GLM_MEMBERS_EVENTS_PLUGIN_DB_PREFIX . "categories
-                  WHERE name = %d",
-                $category
+                  WHERE lower(name) = %d",
+                strtolower($category)
             )
         );
         if ( $category_id ) {