@@ -1090,22 +1090,22 @@ def find_delegation(self):
10901090 def printTable (items , header ):
10911091 colLen = []
10921092 try :
1093- for i , col in enumerate (header ):
1094- rowMaxLen = max (len (str (row [i ])) for row in items )
1095- colLen .append (max (rowMaxLen , len (col )))
1096-
1097- # Create the format string for each row
1098- outputFormat = " " .join ([f"{{{ num } :{ width } s}}" for num , width in enumerate (colLen )])
1099-
1100- # Print header
1101- self .logger .highlight (outputFormat .format (* header ))
1102- self .logger .highlight (" " .join (["-" * itemLen for itemLen in colLen ]))
1103-
1104- # Print rows
1105- for row in items :
1106- self .logger .highlight (outputFormat .format (* row ))
1107- except Exception as e :
1108- self .logger .fail ("Header Index error " + str (e )) # Seen in line rowMaxlen and highlight row variable
1093+ for i , col in enumerate (header ):
1094+ rowMaxLen = max (len (str (row [i ])) for row in items )
1095+ colLen .append (max (rowMaxLen , len (col )))
1096+
1097+ # Create the format string for each row
1098+ outputFormat = " " .join ([f"{{{ num } :{ width } s}}" for num , width in enumerate (colLen )])
1099+
1100+ # Print header
1101+ self .logger .highlight (outputFormat .format (* header ))
1102+ self .logger .highlight (" " .join (["-" * itemLen for itemLen in colLen ]))
1103+
1104+ # Print rows
1105+ for row in items :
1106+ self .logger .highlight (outputFormat .format (* row ))
1107+ except Exception as e :
1108+ self .logger .fail ("Header Index error " + str (e ))
11091109
11101110 # Building the search filter
11111111 search_filter = ("(&(|(UserAccountControl:1.2.840.113556.1.4.803:=16777216)(UserAccountControl:1.2.840.113556.1.4.803:="
0 commit comments