Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Login don't pause terminal when using callback #538

Closed
jcubic opened this issue Nov 7, 2019 · 0 comments
Closed

Login don't pause terminal when using callback #538

jcubic opened this issue Nov 7, 2019 · 0 comments
Labels
Bug resolved if issue is resolved, it will be open until merge with master

Comments

@jcubic
Copy link
Owner

jcubic commented Nov 7, 2019

Expected behavior

I should not see password: again when login in

Actual behavior

The terminal is not paused when I log in, so I see the password: prompt again.

Steps to reproduce

function delay(n) {
    return new Promise(resolve => setTimeout(resolve, n));
}
$(function() {
    $('body').terminal($.noop, {
        greetings: 'Welcome ' + id,
        name: 'term_' + id,
        login: function(u, p, c) {
            delay(5000).then(() => c(u + ':' + p));
        }
    });
});

found when trying to reproduce the issue from #537

@jcubic jcubic added the Bug label Nov 7, 2019
jcubic added a commit that referenced this issue Nov 24, 2019
@jcubic jcubic added the resolved if issue is resolved, it will be open until merge with master label Nov 24, 2019
@jcubic jcubic closed this as completed Nov 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug resolved if issue is resolved, it will be open until merge with master
Projects
None yet
Development

No branches or pull requests

1 participant