File tree Expand file tree Collapse file tree 2 files changed +4
-14
lines changed
Expand file tree Collapse file tree 2 files changed +4
-14
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change 7171import Vue from " vue" ;
7272import { mapState } from " vuex" ;
7373import * as QRGen from " qrcode-generator" ;
74- import { OTPEntry , OTPType , CodeState } from " ../../models/otp" ;
74+ import { OTPEntry , OTPType , CodeState , OTPAlgorithm } from " ../../models/otp" ;
7575
7676import IconMinusCircle from " ../../../svg/minus-circle.svg" ;
7777import IconRedo from " ../../../svg/redo.svg" ;
@@ -252,7 +252,9 @@ function getQrUrl(entry: OTPEntry) {
252252 ? " &period=" + entry .period
253253 : " " ) +
254254 (entry .digits !== 6 ? " &digits=" + entry .digits : " " ) +
255- (entry .algorithm ? " &algorithm=" + entry .algorithm : " " );
255+ (entry .algorithm !== OTPAlgorithm .SHA1
256+ ? " &algorithm=" + OTPAlgorithm [entry .algorithm ]
257+ : " " );
256258 const qr = QRGen (0 , " L" );
257259 qr .addData (otpauth );
258260 qr .make ();
You can’t perform that action at this time.
0 commit comments