One more time
authorChuck Scott <cscott@gaslightmedia.com>
Mon, 11 May 2015 19:41:34 +0000 (15:41 -0400)
committerChuck Scott <cscott@gaslightmedia.com>
Mon, 11 May 2015 19:41:34 +0000 (15:41 -0400)
classes/glmMemberImportFromConnections.php

index 47fa6ec..f42b137 100644 (file)
@@ -418,6 +418,12 @@ class GlmMemberImportFromConnections
                     if ($logo === false) {
                         $logo = '';
                     }
+                } elseif (isset($m['options']['image'])) {
+                    $imagePath = $m['options']['image']['meta']['path'];
+                    $image = $this->storeImage($imagePath);
+                    if ($image === false) {
+                        $image = '';
+                    }
                 }
 
                 $t = date('Y-m-d H:i:s', time());
@@ -513,18 +519,6 @@ class GlmMemberImportFromConnections
                     }
                 }
 
-                // Check for additional image
-/*
-                $image = '';
-                if (isset($m['options']['image'])) {
-                    $imagePath = $m['options']['image']['meta']['path'];
-                    $image = $this->storeImage($imagePath);
-                    if ($image === false) {
-                        $image = '';
-                    }
-                }
-*/
-
                 $membersImported++;
             }
 
@@ -545,7 +539,7 @@ class GlmMemberImportFromConnections
     // If we have a good image
     public function storeImage($image)
     {
-echo $image."<br>";
+
         // Get new image using temporary file name
         $newImage = wp_get_image_editor($image);