fix syntax error

This commit is contained in:
thez3ro 2017-11-07 14:07:47 +01:00
parent fbfc2e4d07
commit a4bdc9a71d
No known key found for this signature in database
GPG Key ID: F628F9E41DD7C073

View File

@ -356,13 +356,16 @@ bool AutoType::parseActions(const QString& sequence, const Entry* entry, QList<A
} }
for (const QChar &ch : sequence) { for (const QChar &ch : sequence) {
if (inTmpl) {
if (ch == '{') { if (ch == '{') {
qWarning("Syntax error in auto-type sequence."); qWarning("Syntax error in auto-type sequence.");
return false; return false;
} }
else if (ch == '}') { else if (ch == '}') {
QList<AutoTypeAction*> autoType = createActionFromTemplate(tmpl, entry); QList<AutoTypeAction *> autoType = createActionFromTemplate(tmpl, entry);
if (autoType.isEmpty()) return false; if (autoType.isEmpty()) {
return false;
}
actions.append(autoType); actions.append(autoType);
inTmpl = false; inTmpl = false;
tmpl.clear(); tmpl.clear();