More code review fixes
This commit is contained in:
@@ -509,7 +509,7 @@ exports.MenuModule = class MenuModule extends PluginModule {
|
||||
|
||||
this.optionalMoveToPosition(position);
|
||||
|
||||
return theme.displayThemedPause(this.client, position, cb);
|
||||
return theme.displayThemedPause(this.client, {position}, cb);
|
||||
}
|
||||
|
||||
promptForInput( { formName, formId, promptName, prevFormName, position } = {}, options, cb) {
|
||||
|
||||
@@ -585,8 +585,8 @@ function displayThemedPrompt(name, client, options, cb) {
|
||||
return callback(null, promptConfig, artInfo);
|
||||
}
|
||||
|
||||
if(options.row != null) {
|
||||
artInfo.startRow = options.row;
|
||||
if(!_.isNil(options) && !_.isNil(options.position) && !_.isNil(options.position.row)) {
|
||||
artInfo.startRow = options.position.row;
|
||||
if(client.term.termHeight > 0 && artInfo.startRow + artInfo.height > client.term.termHeight) {
|
||||
// in this case, we will have scrolled
|
||||
artInfo.startRow = client.term.termHeight - artInfo.height;
|
||||
|
||||
Reference in New Issue
Block a user