jenkins-bot has submitted this change and it was merged.
Change subject: When location search equals '?new' editor content is not being
restored.
......................................................................
When location search equals '?new' editor content is not being restored.
Bug: T128851
Change-Id: Id08b68e383467299db9dcc7fb31dca979283ff25
---
M wikibase/queryService/ui/App.js
1 file changed, 3 insertions(+), 1 deletion(-)
Approvals:
Smalyshev: Looks good to me, approved
jenkins-bot: Verified
diff --git a/wikibase/queryService/ui/App.js b/wikibase/queryService/ui/App.js
index c3ce269..b7f726c 100644
--- a/wikibase/queryService/ui/App.js
+++ b/wikibase/queryService/ui/App.js
@@ -162,7 +162,6 @@
**/
SELF.prototype._initQuery = function() {
if ( window.location.hash !== '' ) {
-
if( location.hash.indexOf( '#result#' ) === 0 ){
location.hash = location.hash.replace(
'#result#', '#' );
}
@@ -171,6 +170,9 @@
this._editor.refresh();
}else{
+ if( location.search === ( '?new' )){
+ return;
+ }
this._editor.restoreValue();
}
};
--
To view, visit https://gerrit.wikimedia.org/r/276736
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Id08b68e383467299db9dcc7fb31dca979283ff25
Gerrit-PatchSet: 1
Gerrit-Project: wikidata/query/gui
Gerrit-Branch: master
Gerrit-Owner: Jonas Kress (WMDE) <[email protected]>
Gerrit-Reviewer: Smalyshev <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits