diff options
author | Martin <martin.basti@gmail.com> | 2016-07-02 22:22:56 +0200 |
---|---|---|
committer | Martin <martin.basti@gmail.com> | 2016-07-02 22:22:56 +0200 |
commit | abbd92e6e1acafd66e2d10e2babc00fb8b8cab1a (patch) | |
tree | 0fefa5131c604829ed8c6743579b58e735c64791 /examples | |
parent | 968c6160a2bec0875a4ff64db3bae3d1925de3db (diff) | |
download | dnspython-abbd92e6e1acafd66e2d10e2babc00fb8b8cab1a.tar.gz |
Pylint: examples: fix redefined variables from outer scope
Diffstat (limited to 'examples')
-rwxr-xr-x | examples/zonediff.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/examples/zonediff.py b/examples/zonediff.py index f388c17..deafa07 100755 --- a/examples/zonediff.py +++ b/examples/zonediff.py @@ -142,8 +142,9 @@ def format_changes_html(oldf, newf, changes, ignore_ttl=False): ret += ' </tr>\n' return ret + ' </tbody>\n</table>' + # Make this module usable as a script too. -if __name__ == '__main__': +def main(): import optparse import subprocess import sys @@ -269,3 +270,6 @@ The differences shown will be logical differences, not textual differences. else: print(format_changes_plain(oldn, newn, changes, opts.ignore_ttl)) sys.exit(1) + +if __name__ == '__main__': + main() |