diff options
author | 2012-03-07 12:10:17 +0100 | |
---|---|---|
committer | 2012-03-07 12:10:17 +0100 | |
commit | 135e153016535273dcd65d02bf03316355630cfb (patch) | |
tree | 177aef0c7b1b5c6806977a4cab893717693e28a3 /scripts | |
parent | Check if the given bugnumber is an integer (diff) | |
download | tatt-135e153016535273dcd65d02bf03316355630cfb.tar.gz tatt-135e153016535273dcd65d02bf03316355630cfb.tar.bz2 tatt-135e153016535273dcd65d02bf03316355630cfb.zip |
Fix -r option without -b
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/tatt | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/scripts/tatt b/scripts/tatt index bba5bde..d8206c2 100755 --- a/scripts/tatt +++ b/scripts/tatt @@ -87,13 +87,15 @@ parser.add_option("-o", "--overview" "--browse", config['verbose']=options.verbose # Normalize the template dir: config['template-dir']=os.path.abspath(config['template-dir'])+os.sep -# Test if the bugnumber represents an int +# If given, test if the bugnumber represents an int try: int(options.bugnum) except ValueError: print ("The bugnumber you gave with -b should be an integer.") exit(1); - +except TypeError: + # This occurs if bugnum is None, that is, -b was not given + pass ## Checking for root, tatt should be run as a user, I guess. ## Remove on occasion. |