dynconfig/wscript: python3 fix string.find instance
authorNoel Power <noel.power@suse.com>
Tue, 11 Dec 2018 12:12:08 +0000 (12:12 +0000)
committerAndrew Bartlett <abartlet@samba.org>
Thu, 13 Dec 2018 23:51:32 +0000 (00:51 +0100)
string.find doesn't exist in python3. Instead use the 'find' method
of the string instance itself

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
dynconfig/wscript

index e9ca4e5..e352712 100644 (file)
@@ -46,7 +46,7 @@ class SambaIndentedHelpFormatter (optparse.IndentedHelpFormatter):
         result.append(opts)
         if option.help:
             help_text = self.expand_default(option)
-            if string.find(help_text, '\n') == -1:
+            if help_text.find('\n') == -1:
                 help_lines = textwrap.wrap(help_text, self.help_width)
             else:
                 help_lines = help_text.splitlines()