Skip to content

Commit

Permalink
Fix CodeQL (#5310)
Browse files Browse the repository at this point in the history
  • Loading branch information
compulim authored Sep 25, 2024
1 parent f1a84bb commit 1bb7c04
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion __tests__/html/speechRecognition.simple.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<!DOCTYPE html>
<!doctype html>
<html lang="en-US">
<head>
<link href="/assets/index.css" rel="stylesheet" type="text/css" />
Expand Down Expand Up @@ -53,7 +53,9 @@
let speechSynthesisHostname;
let speechRegion;

// CodeQL [SM01513] False positive, not bypassing, but switching between approaches
if (useSubscriptionKey) {
// CodeQL [SM01513] False positive, not bypassing, but switching between approaches
if (channelType === 'dlspeech' && directLineSpeechSubscriptionKey) {
speechAuthorizationToken = await fetchSpeechServicesAuthorizationToken({
region: directLineSpeechRegion,
Expand All @@ -67,6 +69,7 @@
} else {
speechRegion = directLineSpeechRegion;
}
// CodeQL [SM01513] False positive, not bypassing, but switching between approaches
} else if (channelType === 'dl' && speechServicesSubscriptionKey) {
speechAuthorizationToken = await fetchSpeechServicesAuthorizationToken({
region: speechServicesRegion,
Expand Down
2 changes: 1 addition & 1 deletion __tests__/setup/NUnitTestReporter.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const os = require('os');
const stripANSI = require('strip-ansi');

const hash = value => {
const hash = createHash('sha1');
const hash = createHash('sha512');

hash.update(value);

Expand Down

0 comments on commit 1bb7c04

Please sign in to comment.