Merge pull request #657 from BlueGreenMagick/prof-name

don't allow addons21 as profile name
This commit is contained in:
Damien Elmes 2020-06-08 11:30:27 +10:00 committed by GitHub
commit 26330da119
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -265,8 +265,8 @@ class AnkiQt(QMainWindow):
# will be shown again
self.loadProfile(self.profileDiag.closeWithoutQuitting)
def profileNameOk(self, str):
return not checkInvalidFilename(str)
def profileNameOk(self, name: str) -> bool:
return not checkInvalidFilename(name) and name != "addons21"
def onAddProfile(self):
name = getOnlyText(_("Name:")).strip()