1
0
Fork 0
mirror of https://github.com/Zedfrigg/ironbar.git synced 2025-08-17 23:01:04 +02:00

refactor: update mlua crate

This commit is contained in:
Jake Stanger 2025-04-04 20:32:58 +01:00
parent 28a0e0fb99
commit fc249497aa
No known key found for this signature in database
GPG key ID: C51FC8F9CB0BEA61
3 changed files with 51 additions and 7 deletions

View file

@ -160,9 +160,7 @@ impl Module<gtk::Box> for CairoModule {
let ptr = unsafe { cr.clone().into_glib_ptr().cast() };
// mlua needs a valid return type, even if we don't return anything
if let Err(err) =
function.call::<_, Option<bool>>((id.as_str(), LightUserData(ptr)))
{
if let Err(err) = function.call::<Option<bool>>((id.as_str(), LightUserData(ptr))) {
if let Error::RuntimeError(message) = err {
let message = message.split_once("]:").expect("to exist").1;
error!("[lua runtime error] {}:{message}", path.display());