From 9d91d2d83bcecb5f2d441b3a40cf1ecae306ea06 Mon Sep 17 00:00:00 2001 From: wusongqing Date: Tue, 26 Apr 2022 16:39:36 +0800 Subject: [PATCH] updated docs Signed-off-by: wusongqing --- .../reference/apis/js-apis-system-vibrate.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/en/application-dev/reference/apis/js-apis-system-vibrate.md b/en/application-dev/reference/apis/js-apis-system-vibrate.md index a4cbe37463..f62074d374 100644 --- a/en/application-dev/reference/apis/js-apis-system-vibrate.md +++ b/en/application-dev/reference/apis/js-apis-system-vibrate.md @@ -3,7 +3,7 @@ > ![icon-note.gif](public_sys-resources/icon-note.gif) **NOTE** > - The initial APIs of this module are supported since API version 4. Newly added APIs will be marked with a superscript to indicate their earliest API version. -> - The APIs of this module are no longer maintained since API version 8. You are advised to use [Vibrator](js-apis-vibrator.md) instead. +> - The APIs of this module are no longer maintained since API version 8. You are advised to use [`@ohos.vibrator`](js-apis-vibrator.md) instead. > - This module requires hardware support and can only be debugged on real devices. @@ -36,13 +36,13 @@ Triggers device vibration. ``` vibrator.vibrate({ mode: 'short', - success: function(ret) { + success: function() { console.log('vibrate is successful'); }, - fail: function(ret) { - console.log('vibrate is failed'); + fail: function(data, code) { + console.log("vibrate is failed, data: " + data + ", code: " + code); }, - complete: function(ret) { + complete: function() { console.log('vibrate is completed'); } }); -- GitLab