mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/OATHAuth
synced 2024-11-24 00:05:24 +00:00
Fix QR code generation module dependency
Bug: T118511 Change-Id: Idf11e9a469f9e9faa342d82843cf06f7e47406c6
This commit is contained in:
parent
e743f45af7
commit
3bb7cd6440
|
@ -116,9 +116,16 @@ class SpecialOATH extends UnlistedSpecialPage {
|
|||
. '<div id="qrcode"></div>';
|
||||
|
||||
$this->getOutput()->addHTML( ResourceLoader::makeInlineScript(
|
||||
'jQuery("#qrcode").qrcode("otpauth://totp/'
|
||||
. $this->OATHUser->getAccount()
|
||||
. '?secret=' . $secret . '")'
|
||||
Xml::encodeJsCall( 'mw.loader.using', array(
|
||||
array( 'ext.oathauth' ),
|
||||
new XmlJsCode(
|
||||
'function () {'
|
||||
. '$("#qrcode").qrcode("otpauth://totp/'
|
||||
. $this->OATHUser->getAccount()
|
||||
. '?secret=' . $secret. '");'
|
||||
. '}'
|
||||
)
|
||||
) )
|
||||
) );
|
||||
|
||||
$this->getOutput()->addHTML( $out );
|
||||
|
|
Loading…
Reference in a new issue