Skip to content

Commit

Permalink
Better error message for SSH private key select box
Browse files Browse the repository at this point in the history
  • Loading branch information
NI committed Sep 2, 2019
1 parent f0d097a commit c0ad0ad
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions ui/commands/ssh.js
Original file line number Diff line number Diff line change
Expand Up @@ -353,11 +353,13 @@ const initialFieldDef = {
let firstLineReaded = false;

for (let i in lines) {
if (!firstLineReaded && lines[i].indexOf("-") === 0) {
firstLineReaded = true;
if (!firstLineReaded) {
if (lines[i].indexOf("-") === 0) {
firstLineReaded = true;

if (lines[i].indexOf("RSA") < 0) {
break;
if (lines[i].indexOf("RSA") <= 0) {
break;
}
}

continue;
Expand Down

0 comments on commit c0ad0ad

Please sign in to comment.