mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-15 02:23:58 +00:00
Fixes: Error: Bad constructor arguments
Change-Id: I2f1146946bfb96d50f9580f2f7a9bd5dcb926ef1
This commit is contained in:
parent
9fbd0aae6f
commit
29efc96cd5
|
@ -619,7 +619,13 @@
|
|||
// Add section is currently a wikitext-only feature
|
||||
'#ca-addsection a'
|
||||
).each( function () {
|
||||
var linkUri = new mw.Uri( this.href );
|
||||
var linkUri;
|
||||
try {
|
||||
linkUri = new mw.Uri( this.href );
|
||||
} catch ( e ) {
|
||||
// T66884
|
||||
return;
|
||||
}
|
||||
if ( 'action' in linkUri.query ) {
|
||||
delete linkUri.query.action;
|
||||
linkUri.query.veaction = 'editsource';
|
||||
|
|
Loading…
Reference in a new issue