HomeDocs
Skip to main content

UpdateManager.onUpdateFailed

Introduction​

Listen for the mini-program update failure event. When a new version of the mini-program is available, the client actively triggers the download (without the need for the developer to trigger it), and if the download fails (due to reasons such as network issues), this callback is executed.

Parameters​

None

Sample Code​

Page({
onLoad() {
const updateManager = dlt.getUpdateManager();
updateManager.onUpdateFailed(function (res) {
// New version download failed
});
},
});
Privacy agreementDeveloper agreementcontact us: developer_private.mi@dlightek.com © 2024 MiniApp. All Rights Reserved.