Commits

William Headrick committed c924fb3

Default tortoisehg.bugtraqparameters to empty string.

Fixes issue from rev #12632 where 'NoneType' passed to
os.path.expandvars would fail as "not iterable"

File "/home/billhead/Development/TortoiseHg/thg/thg/tortoisehg/hgqt/commit.py", line 63, in __init__
opts['bugtraqparameters'] = os.path.expandvars(repo.ui.config('tortoisehg', 'issue.bugtraqparameters', None))
File "/usr/lib/python2.6/posixpath.py", line 280, in expandvars
if '$' not in path:
TypeError: argument of type 'NoneType' is not iterable

Comments (0)

Files changed (1)

tortoisehg/hgqt/commit.py

 # commit.py - TortoiseHg's commit widget and standalone dialog
 #
-# Copyright 2010 Steve Borho <steve@borho.org>
+# Copyright 2010-2012 Steve Borho <steve@borho.org>
 #
 # This software may be used and distributed according to the terms of the
 # GNU General Public License version 2, incorporated herein by reference.
         opts['autoinc'] = repo.ui.config('tortoisehg', 'autoinc', '')
         opts['recurseinsubrepos'] = repo.ui.config('tortoisehg', 'recurseinsubrepos', None)
         opts['bugtraqplugin'] = repo.ui.config('tortoisehg', 'issue.bugtraqplugin', None)
-        opts['bugtraqparameters'] = os.path.expandvars(repo.ui.config('tortoisehg', 'issue.bugtraqparameters', None))
+        opts['bugtraqparameters'] = os.path.expandvars(repo.ui.config('tortoisehg', 'issue.bugtraqparameters', ''))
         opts['bugtraqtrigger'] = repo.ui.config('tortoisehg', 'issue.bugtraqtrigger', None)
         self.opts = opts # user, date
 
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.