mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-21 06:48:00 +01:00
Fix completion list for functions that return augmented arrays.
This commit is contained in:
@@ -273,7 +273,7 @@ const CompletionContext = Class("CompletionContext", {
|
|||||||
get completions() this._completions || [],
|
get completions() this._completions || [],
|
||||||
set completions(items) {
|
set completions(items) {
|
||||||
// Accept a generator
|
// Accept a generator
|
||||||
if (!isArray(items))
|
if (!(isArray(items) || isArray(items.__proto__)))
|
||||||
items = [x for (x in Iterator(items || []))];
|
items = [x for (x in Iterator(items || []))];
|
||||||
if (this._completions !== items) {
|
if (this._completions !== items) {
|
||||||
delete this.cache.filtered;
|
delete this.cache.filtered;
|
||||||
|
|||||||
@@ -303,9 +303,7 @@ const Editor = Module("editor", {
|
|||||||
if (!options["editor"])
|
if (!options["editor"])
|
||||||
return;
|
return;
|
||||||
|
|
||||||
let textBox = null;
|
let textBox = config.isComposeWindow ? null : dactyl.focus;
|
||||||
if (!(config.isComposeWindow))
|
|
||||||
textBox = dactyl.focus;
|
|
||||||
|
|
||||||
if (!forceEditing && textBox && textBox.type == "password") {
|
if (!forceEditing && textBox && textBox.type == "password") {
|
||||||
commandline.input("Editing a password field externally will reveal the password. Would you like to continue? (yes/[no]): ",
|
commandline.input("Editing a password field externally will reveal the password. Would you like to continue? (yes/[no]): ",
|
||||||
|
|||||||
Reference in New Issue
Block a user