提交 f7eff84d 编写于 作者: inkwalk's avatar inkwalk

fix: type warning

上级 52d30fbd
...@@ -12,7 +12,7 @@ export const getScreenBrightness = ...@@ -12,7 +12,7 @@ export const getScreenBrightness =
defineAsyncApi<API_TYPE_GET_SCREEN_BRIGHTNESS>( defineAsyncApi<API_TYPE_GET_SCREEN_BRIGHTNESS>(
API_GET_SCREEN_BRIGHTNESS, API_GET_SCREEN_BRIGHTNESS,
(_, { resolve }) => { (_, { resolve }) => {
const value = plus.screen.getBrightness(false) const value = plus.screen.getBrightness()
resolve({ value }) resolve({ value })
} }
) )
...@@ -21,7 +21,7 @@ export const setScreenBrightness = ...@@ -21,7 +21,7 @@ export const setScreenBrightness =
defineAsyncApi<API_TYPE_SET_SCREEN_BRIGHTNESS>( defineAsyncApi<API_TYPE_SET_SCREEN_BRIGHTNESS>(
API_SET_SCREEN_BRIGHTNESS, API_SET_SCREEN_BRIGHTNESS,
(options, { resolve }) => { (options, { resolve }) => {
plus.screen.setBrightness(options.value, false) plus.screen.setBrightness(options.value)
resolve() resolve()
} }
) )
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册