accept backends name with only letters and digits
This commit is contained in:
parent
f4e2588842
commit
0746942e02
2 changed files with 7 additions and 1 deletions
|
|
@ -241,7 +241,7 @@ class ReplApplication(Cmd, BaseApplication):
|
|||
except BackendAlreadyExists:
|
||||
print 'Backend "%s" is already configured in file "%s"' % (name, self.weboob.backends_config.confpath)
|
||||
while self.ask('Add new instance of "%s" backend?' % name, default=False):
|
||||
new_name = self.ask('Please give new instance name (could be "%s_1")' % name, regexp=u'^[\d\w_-]+$')
|
||||
new_name = self.ask('Please give new instance name (could be "%s_1")' % name, regexp=r'^[\w\-_]+$')
|
||||
try:
|
||||
self.weboob.backends_config.add_backend(new_name, name, params)
|
||||
print 'Backend "%s" successfully added.' % new_name
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue