Switch to async closures
All checks were successful
Build and deploy / build (push) Successful in 9m0s
Build and deploy / Deploy container (push) Successful in 42s

This commit is contained in:
2025-09-01 03:18:56 +02:00
parent e21ea0f34e
commit 4a83250258
8 changed files with 109 additions and 124 deletions

View File

@@ -99,7 +99,7 @@ impl AddAdditionalMethods for HueBridge {
{
methods.add_async_method(
"set_flag",
|lua, this, (flag, value): (mlua::Value, bool)| async move {
async |lua, this, (flag, value): (mlua::Value, bool)| {
let flag: Flag = lua.from_value(flag)?;
this.set_flag(flag, value).await;

View File

@@ -170,7 +170,7 @@ impl AddAdditionalMethods for Ntfy {
{
methods.add_async_method(
"send_notification",
|lua, this, notification: mlua::Value| async move {
async |lua, this, notification: mlua::Value| {
let notification: Notification = lua.from_value(notification)?;
this.send(notification).await;