Skip to content
This repository has been archived by the owner on Jan 13, 2025. It is now read-only.

Commit

Permalink
Fix: Typo
Browse files Browse the repository at this point in the history
  • Loading branch information
AnYiEE committed Apr 19, 2023
1 parent 358026b commit 42bf011
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions static/wikimirror.js
Original file line number Diff line number Diff line change
Expand Up @@ -1180,7 +1180,7 @@ const WikiMirrorPrivateMethod = class WikiMirrorPrivateMethod {
} else {
pos = 'p-cactions';
}
const doIns = async ({dec, tex, link, prema}) => {
const doIns = async ({dec, tex, link, perma}) => {
let dom = document.getElementById(ID);
if (dom === null) {
await mw.loader.using('mediawiki.util');
Expand All @@ -1198,7 +1198,7 @@ const WikiMirrorPrivateMethod = class WikiMirrorPrivateMethod {
e.preventDefault();
await mw.loader.using(['mediawiki.widgets', 'oojs-ui-windows']);
const $dom = jQuery('<div>');
[link, `[[${link}${prema ? this.decodeURIComponent(this.getLocate('originHash')) : ''}]]`].forEach(
[link, `[[${link}${perma ? this.decodeURIComponent(this.getLocate('originHash')) : ''}]]`].forEach(
(value) => {
$dom.append(new mw.widgets.CopyTextLayout({align: 'top', copyText: value}).$element);
}
Expand Down Expand Up @@ -1233,7 +1233,7 @@ const WikiMirrorPrivateMethod = class WikiMirrorPrivateMethod {
diffId === this.getConf('wgDiffNewId') &&
response.compare?.fromrevid === this.getConf('wgDiffOldId')
) {
buildLink(0);
buildLink(false);
}
} catch (e) {
this.showNetworkErrorNotice();
Expand All @@ -1250,7 +1250,7 @@ const WikiMirrorPrivateMethod = class WikiMirrorPrivateMethod {
dec: t('Copy the permanent link to the current version (wiki syntax)'),
tex: t('Permanent link'),
link: `Special:PermaLink/${revisionId}`,
prema: true,
perma: true,
});
}
}
Expand Down

0 comments on commit 42bf011

Please sign in to comment.