Tweak code ordering in port_get_mode

Change-Id: Ifd3929f6006116ffc1284ebfc8b55adf782c2392
diff --git a/drivers/NetgearXSM.py b/drivers/NetgearXSM.py
index 57da90f..2e608fd 100644
--- a/drivers/NetgearXSM.py
+++ b/drivers/NetgearXSM.py
@@ -312,17 +312,18 @@
                 match = tagging_re.match(line)
                 if match:
                     tagging = match.group(1)
+                    
+            # Simple classifier for now; may need to revisit later...
+            if (acceptframe == "admituntaggedonly" and ingressfilter):
+                return "access"
+            else:
+                return "trunk"
 
         except PExpectError:
             # recurse on error
             self._switch_connect()
             return self.port_get_mode(port)
 
-        # Simple classifier for now; may need to revisit later...
-        if (acceptframe == "admituntaggedonly" and ingressfilter == True):
-            return "access"
-        else:
-            return "trunk"
 
     # Set an access port to be in a specified VLAN (tag)
     def port_set_access_vlan(self, port, tag):