mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-12 09:09:25 +00:00
Merge "Also allow opening in source mode if VE is unavailable on action=edit"
This commit is contained in:
commit
4abdf21413
|
@ -914,7 +914,12 @@
|
|||
if ( isViewPage && uri.query.veaction in editModes ) {
|
||||
mode = editModes[ uri.query.veaction ];
|
||||
} else {
|
||||
if ( init.isWikitextAvailable && getPreferredEditor() === 'wikitext' ) {
|
||||
if ( init.isWikitextAvailable && (
|
||||
getPreferredEditor() === 'wikitext' || (
|
||||
!init.isVisualAvailable &&
|
||||
[ 'edit', 'submit' ].indexOf( uri.query.action ) !== -1
|
||||
)
|
||||
) ) {
|
||||
mode = 'source';
|
||||
} else {
|
||||
mode = 'visual';
|
||||
|
|
Loading…
Reference in a new issue