Replace 2 regexes with a single one
No functional changes Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de> Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
This commit is contained in:
parent
c6259fbb86
commit
535f4592fc
@ -34,8 +34,9 @@ class LocalStatusRepository(BaseRepository):
|
||||
return '.'
|
||||
|
||||
def getfolderfilename(self, foldername):
|
||||
foldername = re.sub('/\.$', '/dot', foldername)
|
||||
foldername = re.sub('^\.$', 'dot', foldername)
|
||||
"""Return the full path of the status file"""
|
||||
# replace with 'dot' if final path name is '.'
|
||||
foldername = re.sub('(^|\/)\.$','\\1dot', foldername)
|
||||
return os.path.join(self.directory, foldername)
|
||||
|
||||
def makefolder(self, foldername):
|
||||
|
Loading…
Reference in New Issue
Block a user