@@ -367,21 +367,27 @@ FocusScope {
367367 onUnlocked: lockscreen.hide()
368368 onCancel: greeter.show()
369369
370− Component.onCompleted: LightDM.Greeter.authenticate(LightDM.Users.data(0, LightDM.UserRoles.NameRole))
370+ Component.onCompleted: {
371+ if (LightDM.Users.count == 1) {
372+ LightDM.Greeter.authenticate(LightDM.Users.data(0, LightDM.UserRoles.NameRole))
373+ }
374+ }
371375 }
372376
373377 Connections {
374378 target: LightDM.Greeter
375379
376380 onShowPrompt: {
377− // TODO: There's no better way for now to determine if its a PIN or a passphrase.
378− if (text == "PIN") {
379− lockscreen.alphaNumeric = false
380− } else {
381− lockscreen.alphaNumeric = true
381+ if (LightDM.Users.count == 1) {
382+ // TODO: There's no better way for now to determine if its a PIN or a passphrase.
383+ if (text == "PIN") {
384+ lockscreen.alphaNumeric = false
385+ } else {
386+ lockscreen.alphaNumeric = true
387+ }
388+ lockscreen.placeholderText = i18n.tr("Please enter %1:").arg(text);
389+ lockscreen.show();
382390 }
383− lockscreen.placeholderText = i18n.tr("Please enter %1:").arg(text);
384− lockscreen.show();
385391 }
386392 }
387393