Fix no buildkey (#3427)

master
Mark Haslinghuis 2023-04-19 00:52:45 +02:00 committed by GitHub
parent 466a71e954
commit 61e31e4250
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 4 deletions

View File

@ -579,14 +579,16 @@ firmware_flasher.initialize = function (callback) {
if (semver.gte(FC.CONFIG.apiVersion, API_VERSION_1_45) && navigator.onLine) { if (semver.gte(FC.CONFIG.apiVersion, API_VERSION_1_45) && navigator.onLine) {
function onLoadCloudBuild(options) { function onLoadCloudBuild(options) {
if (FC.CONFIG.buildKey.length === 32) { FC.CONFIG.buildOptions = options.Request.Options;
FC.CONFIG.buildOptions = options.Request.Options;
}
getBoardInfo(); getBoardInfo();
} }
MSP.send_message(MSPCodes.MSP2_GET_TEXT, mspHelper.crunch(MSPCodes.MSP2_GET_TEXT, MSPCodes.BUILD_KEY), false, () => { MSP.send_message(MSPCodes.MSP2_GET_TEXT, mspHelper.crunch(MSPCodes.MSP2_GET_TEXT, MSPCodes.BUILD_KEY), false, () => {
self.releaseLoader.requestBuildOptions(FC.CONFIG.buildKey, onLoadCloudBuild, getBoardInfo); if (FC.CONFIG.buildKey.length === 32) {
self.releaseLoader.requestBuildOptions(FC.CONFIG.buildKey, onLoadCloudBuild, getBoardInfo);
} else {
getBoardInfo();
}
}); });
} else { } else {
getBoardInfo(); getBoardInfo();