mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Cite
synced 2024-11-24 15:04:02 +00:00
ve.ui.MWCitationDialog: Fix condition for enabling insert/apply action
The method #hasUsefulParameter has been accidentally made to always
return false in fdde5b71af
.
Bug: T210686
Change-Id: I215924c2f693842abd8026404d17c725192272c3
This commit is contained in:
parent
57aeb852ae
commit
7f6ae77b3c
|
@ -146,8 +146,7 @@ ve.ui.MWCitationDialog.prototype.onAddParameterBeforeLoad = function ( page ) {
|
||||||
* @return {boolean}
|
* @return {boolean}
|
||||||
*/
|
*/
|
||||||
ve.ui.MWCitationDialog.prototype.hasUsefulParameter = function () {
|
ve.ui.MWCitationDialog.prototype.hasUsefulParameter = function () {
|
||||||
var name, page,
|
var name, page;
|
||||||
foundUseful = false;
|
|
||||||
|
|
||||||
for ( name in this.bookletLayout.pages ) {
|
for ( name in this.bookletLayout.pages ) {
|
||||||
page = this.bookletLayout.pages[ name ];
|
page = this.bookletLayout.pages[ name ];
|
||||||
|
@ -155,11 +154,10 @@ ve.ui.MWCitationDialog.prototype.hasUsefulParameter = function () {
|
||||||
page instanceof ve.ui.MWParameterPage &&
|
page instanceof ve.ui.MWParameterPage &&
|
||||||
( !page.preLoad || page.valueInput.getValue() !== '' )
|
( !page.preLoad || page.valueInput.getValue() !== '' )
|
||||||
) {
|
) {
|
||||||
foundUseful = true;
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
|
||||||
}
|
|
||||||
return foundUseful;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in a new issue